2014-07-09

JQuery Date and Time picker (Github)

Use this plugin to unobtrusively add a datetimepicker, datepicker or timepicker dropdown to your forms. It's easy to customize options. 


http://xdsoft.net/jqplugins/datetimepicker/
Documentation page & Examples

https://github.com/xdan/datetimepicker

Plupload: Multi-runtime File-Uploader

http://www.plupload.com/

Files not only can be picked from browse dialog, but also can be dropped directly from the desktop.

Files that have to be uploaded can be small or huge - about several gigabytes in size. In such cases standard upload may fail, since browsers still cannot handle it properly. We slice the files in chunks and send them out one by one. You can then safely collect them on the server and combine into original file.

(Great stuff, GPL v2 and OEM license available)

  

2014-07-08

Escaping double-quote hell in aspx pages needing single and double quotes within Eval expressions

http://blog.outsharked.com/2010/12/html-apostrophes-quotes.html

If you use Eval inside your ASPX page, you can avoid using escapes for double quotes by using single quotes for the outermost delimiter e.g. href='<%# Eval("mylink") %>'

But, if you really need to escape the inner double-quote characters, you should use the html way of escaping the quote characters i.e. use " inside the html attribute value. e.g. href="<%#  Eval("mylink" )%>"

http://www.ascii.cl/htmlcodes.htm

2014-07-03

Where to download your software stack for web development (non Microsoft)

https://www.apachefriends.org/download.html

WAMP, MAMP, LAMP



https://bitnami.com/stacks/infrastructure

Just about every possible stack.
Bitnami is an app store for server software. Install your favorite applications in your own servers or run them in the cloud. 

2014-07-01

ASP.Net tutorials: How to handle security and authorization in your Web Forms applications using ASP.NET membership and roles.

http://www.asp.net/web-forms/tutorials/security


Forms Authentication and Role based Authorization: A Quicker, Simpler, and Correct Approach

http://www.codeproject.com/Articles/36836/Forms-Authentication-and-Role-based-Authorization

The code has been modularized to make it easier to use from a utility class
compared with this one
http://www.codeproject.com/Articles/2905/Role-based-Security-with-Forms-Authentication

(For WEBA students, please follow the more updated example in the first link)

Handling auto-generated Identity fields in asp.net using ExecuteScalar

http://www.mikesdotnetting.com/Article/54/Getting-the-identity-of-the-most-recently-added-record

Getting the identity of the most recently added record


The built-in functions @@Identity and Scope_Identity() are designed to retrieve the most recently added record's autoincrement identity value from Access and Sql Server respectively. Here are some examples.(click on link above)

//C#
string query = "Insert Into Categories (CategoryName) Values (@CategoryName);" +
"Select Scope_Identity()";
int ID;
string connect = @"Server=.\SQLExpress;AttachDbFilename=|DataDirectory|Northwind.mdf;" +
    "Database=Northwind;Trusted_Connection=Yes;";
using (SqlConnection conn = new SqlConnection(connect))
{
  using (SqlCommand cmd = new SqlCommand(query, conn))
  {
    cmd.Parameters.AddWithValue("@CategoryName", Category.Text);
    conn.Open();
    ID = (int)cmd.ExecuteScalar();
  }
}

Github CoPilot Alternatives (VSCode extensions)

https://www.tabnine.com/blog/github-copilot-alternatives/