How to use jQuery datepicker

Include these files into your application:
jquery
jquery ui

<link type="text/css" href="/css/jquery-ui.css" rel="stylesheet"/>
<script type="text/javascript" src="/js/jquery-git2.js"></script>
<script type="text/javascript" src="/js/jquery-ui.js"></script>

Javascript Code

$(document).ready(function()
{
    $(function() {
        $( "#datepicker" ).datepicker({
            dateFormat: "dd/mm/yy"
        });
    });
});

Html Code

<label for="datepicker">datepicker</label>
<input type="text" id="datepicker" name="datepicker" value="" />
Categories: HTML & CSS, JQuery Tags: , , ,
%d bloggers like this: