In this article I will explain different
types of Date formats using JQuery in ASP.NET
Create asp Textbox.
<asp:TextBox
ID="txtDate"
runat="server"/>
Different types date formats in JQuery
Example 1:
(dd/mm/yy)
$("#txtDate").datepicker({ dateFormat: 'dd/mm/yy' });
Output: format
(ex: 04/05/2012)
Example 2:
(mm/dd/yy)
$("#txtDate").datepicker({
dateFormat: 'mm/dd/yy' });
Output: format (ex: 05/04/2012)
Example 3:
(yy-mm-dd)
$("#txtDate").datepicker({ dateFormat: 'yy-mm-dd' });
Output: format (ex: 2012-05-04)
Example 4:
(DD,d MM, yy)
$("#txtDate").datepicker({
dateFormat: 'DD, d MM, yy' });
Output: format (ex: Friday,
4 May, 2012)
No comments:
Post a Comment