[英]How to link calender widget to website?
I downloaded a calender widge from site " http://javascriptcalendar.org/javascript-date-picker.php " placed all downloaded files on same folder but not sure how to use the calender in my site 我从网站“ http://javascriptcalendar.org/javascript-date-picker.php ”下载了压光机配件,将所有下载的文件放在同一文件夹中,但不确定如何在我的网站中使用压光机
here is the basic code to be displayed 这是要显示的基本代码
<html>
<head>
<table>
<tr>
<td>to:<script src="calendar.html"></script></td>
<td>from:<script src="calendar.html"></script></td>
</tr>
</table>
</head>
<body>
</body>
</html>
could some please advise how to include it , I am very new your help is much appreciated. 可以请一些建议如何包括它,我很新,非常感谢您的帮助。
Advanced thx Srinivas 高级thrinivas
Basic setup: 基本设置:
HTML: HTML:
<input type="text" size="12" id="inputField" />
JavaScript: JavaScript:
window.onload = function(){
new JsDatePick({
useMode:2,
target:"inputField"
});
};
Copy paste these 2 lines of code to every page you want the calendar to be available at 将这两行代码复制粘贴到希望日历可用的每个页面上
<link rel="stylesheet" type="text/css" media="all" href="jsDatePick_ltr.min.css" />
<script type="text/javascript" src="jsDatePick.min.1.3.js"></script>
Script: 脚本:
<script type="text/javascript">
window.onload = function(){
new JsDatePick({
useMode:2,
target:"inputField",
dateFormat:"%d-%M-%Y"
/*selectedDate:{ This is an example of what the full configuration offers.
day:5, For full documentation about these settings please see the full version of the code.
month:9,
year:2006
},
yearsRange:[1978,2020],
limitToToday:false,
cellColorScheme:"beige",
dateFormat:"%m-%d-%Y",
imgPath:"img/",
weekStartDay:1*/
});
};
</script>
HTML: HTML:
<body>
From:<input type="text" size="12" name="from" id="inputField" />
To: <input type="text" size="12" name="to" id="inputField" />
</body>
Hope this helps. 希望这可以帮助。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.