datePicker dateFormat - input field format does not change
Hello good people :)
I have a problem with the datePicker that I am trying to solve for 2 days now.
Looked at all the tutorials and posts but nothing helped.
My problem is that I want the datePicker to return the date as: dd/mm/yyyy and whatever I tried, the input field that gets the selected date displays it as: Tue Apr 26 2011 00:00:00
Here is my code:
- <head>
<script src="../js/jquery.min.js"></script>
<script type="text/javascript" src="../js/datePicker/date.js"></script>
<script type="text/javascript" src="../js/datePicker/jquery.datePicker.js"></script>
<script type="text/javascript">
$(function()
{
$('.dp')
.datePicker({inline:true})
.bind(
'dateSelected',
function(e, selectedDate, $td)
{
$('.date').val(selectedDate);
}
);
});
</script>
<link href="../js/datePicker/datePicker.css" rel="stylesheet" type="text/css">
</head>
<body>
<form method="post">
<div class="dp"></div>
Date: <input type="text" class="date"></input>
</form>
</body>
Can someone please help?
Thank you ver much,
Sigal