hello guys i want a drop down menu for the month,year and days in case of DATE OF BIRTH.
I HAVE done this thing with jquery datepicker but i want a dropdown menu for it..please help me


here is my code i want to use drop down menu but figuring it out..

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">


<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
<link rel="stylesheet" type="text/css" href="css/stu.css" />
<style type="text/css">
<!--
.style1 {color: #C0C0C0}
-->
</style>
[B]
<link href="../jquery-ui.css"rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../jquery.js"></script>
<script src="../jquery-ui.min.js"></script>


<script>
$(document).ready(function() {
$("#DateOfBirth").datepicker({dateFormat: 'yy-mm-dd '});
});
</script>[/B]
 


</head>


<form id="formID" class="formular" method="post" action="" style="width:600px">
            
 
 
            
         [B]  
  	<input type="text" name="DateOfBirth" id="DateOfBirth"  /> 
    		[/B]
        
        
                


</form

</body>
</html>

Recommended Answers

All 3 Replies

Member Avatar for stbuchok

OK, then create the three dropdowns. What else do you need? What are you stuck on?

is it only creating the dropdown how will be day, month, year will be shown in that dropdown menu...

Member Avatar for stbuchok

For the years dropdown populate it with the years you want (maybe +-50 year of current date)
For the months dropdown, populate it with the numbers 1-12
For the days dropdown, populate it with the number of days in the month that is selected from the months dropdown.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.