<script type="text/
javascript">
function showYear(){
var op = document.getElementById("year").options;
for(var i=2009;i>=1990;i--){
op.add(new Option(i,i));
}
}
function showMonth(){
var op = document.getElementById("month").options;
for(var i=1;i<=12;i++){
op.add(new Option(i,i));
}
}
function check(){
var year = document.getElementById("year").value;
var month= document.getElementById("month").value;
var day_option = document.getElementById("day").options;
day_option.length=0;
if(month=="1" || month=="3" || month=="5" || month=="7" || month=="8" || month=="10" || month=="12"){
for(var i=1;i<=31;i++){
day_option.add(new Option(i,i));
}
}
else if(month=="4" || month=="6" || month=="9" || month=="11"){
for(var i=1;i<=30;i++){
day_option.add(new Option(i,i));
}
}
else if(month=="2"){
if((year%4==0 && year%100!=0) || year%400==0){
for(var i=1;i<=29;i++){
day_option.add(new Option(i,i));
}
}
else{
for(var i=1;i<=28;i++){
day_option.add(new Option(i,i));
}
}
}
}
function load(){
showYear();
showMonth();
check();
}
</script>