Eine der von JavaScript implementierten Einstellungszeit für die von JQuery implementierte Feeling Code ist nicht präzise.
Kopieren Sie den Code -Code wie folgt:
<!
<html xmlns = "http://www.w3.org/1999/xhtml">
<kopf>
<meta http-äquiv = "content-type" content = "text /html; charset = utf-8" /> />
<title> Nicht -Title -Dokument </title>
<Style type = "text/css">
#Lastdate {Farbe:#ff9900;
</style>
</head>
<body>
<div>
<select id = "date_sel" name = "Periode">
<Option Value = "0"> Innerhalb eines Tages </Option>
<Option Value = "1"> Innerhalb von zwei Tagen </Option>
<Option Value = "2"> Innerhalb von drei Tagen </Option>
<Option Value = "3"> Innerhalb von vier Tagen </Option>
</select>
<span> nach <em id = "lastDate"> 2012-9-28 </em>
</div>
<script type = "text/javaScript">
document.getElementById ('Date_sel').
var time = new Date ();
var pre_year = time.getingfoyear ();
var pre_month = time.getMonth ();
var pre_dy = time.getDate ();
var sel_day = parseInt (document.getElementById ('Date_sel'). Wert);
Switch (sel_day) {
Fall 0: Pre_dy += 1;
Fall 1: Pre_Day += 2;
Fall 2: Pre_Day += 3;
Fall 3: Pre_Day += 4;
Standard: Pre_Day += 1;
}
var endime = new Datum (Pre_year, Pre_Month, Pre_Day);
document.getElementById ('lastDate').
};
</script>
</body>
</html>