View the Code directly:
All js files referenced in the Code are packaged (see attachment 1 ). Except jquery-1.6.2.js. This is not directly related to datepicker.
If you want to display Chinese characters, add Attachment 2.
Java code
<Title> jQuery UI Datepicker-Default functionality </title>
<Link rel = "stylesheet" href = "../jquery-ui/css/jquery.ui.all.css">
<Script src = "../jquery-ui/jquery-1.6.2.js"> </script>
<Script src = "../jquery-ui/jquery. ui. core. js"> </script>
<Script src = "../jquery-ui/jquery. ui. widget. js"> </script>
<Script src = "../jquery-ui/jquery. ui. datepicker. js"> </script>
<! -- Display Chinese -->
<Script src = "../jquery-ui/jquery. ui. datepicker-zh-CN.js"> </script>
<Script>
$ (Function (){
$ ("# Datepicker"). datepicker ();
});
$ (Document). ready (function (){
// Alert ("fs ");
// $ ("# Datepicker"). datepicker ();
$ ("# Button"). click (function (){
Alert ($ ("# datepicker"). val ());
});
});
</Script>
</Head>
<Body>
<Div class = "demo">
<Input type = "text" id = "datepicker"/>
<Input type = "button" id = "button" value = "show"/>
</Div> <! -- End demo -->
Some parameter settings:
Java code
$ ("# Datepicker"). datepicker ({
MinDate: new Date ()
});
Author: Zheng Xingyang"