Monthly Archives: January 2014

HTML5 Datalist control

HTML5 Web Development

HTML5 Datalist control is more alike Google Suggest. Before HTML5 presence even for a known list to be suggested, developers go for AJAX request to hit on the database and populate the suggestion list. For every keystroke, an AJAX request is fired. HTML5 ‘Datalist’ could be useful when the form is to be loaded with known list. For example, a form has to be chosen with month. I will explain down with the code how it could be achieved through Datalist HTML5 control.


<!DOCTYPE html>
<title>HTML5 Datalist Demo</title>
<form action="LoginPageSuccess.jsp" method="get">
<input type="text" placeholder="Month Name" id="MonthText" list="getMonthList" required>
<datalist id="getMonthList">
<option value="January"/>
<option value="February"/>
<option value="March"/>
<option value="April"/>
<option value="May"/>
<option value="June"/>
<option value="July"/>
<option value="August"/>
<option value="September"/>
<option value="October"/>
<option value="November"/>
<option value="December"/>


Screenshot of how it works:


View original post

Send attachments with email in PHP

My Blog

Add below function in your PHP file.

Use this function like,

View original post

MVC 4 – Using HTML5 “data-” attributes with Jquery

a developer's notes - a semi-technical web development BLOG

You can create data- HTML attributes with your controls using this technique.

Define a new HTML Attributes anonymous object with your Html helpers. Below, I create a text box with some additional properties I want to be able to access with jQuery. Using properties that start with “data_”, you will be able to access the property with jquery’s data() method. Note: using property names that start with “data-” will result in a compilation error.

This is the HTML that gets rendered

Here is what jquery’s data() method converts property names to. Interestingly, the underscores are removed and camel casing is applied to the name.


Here is another good article on the subject.

View original post

%d bloggers like this: