?? date(1).jsp
字號:
<%@ page contentType="text/html; charset=GBK" %>
<%
String inputName= request.getParameter("inputName");
if(inputName==null || inputName.trim().length()<1){
System.out.println("日期輸入框元素名稱沒有傳遞!");
}
String inputDate = request.getParameter("inputDate");
String _year = "";
String _month = "";
String _date = "";
if(inputDate!=null && inputDate.trim().length()>8){
_year = inputDate.substring(0,4);
_month = inputDate.substring(5,7);
_date = inputDate.substring(8,10);
}
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>日歷</title>
<SCRIPT src="/hollyAgent_demo/framework/public/js/JSCalendar.js"></SCRIPT>
<SCRIPT language="JAVASCRIPT">
function fillBlank(name){
document.all["<%=inputName%>"].value = document.form1.tt.value;
}
</SCRIPT>
</head>
<body >
<form name="form1" method="post" action="" >
<input style="display:none" type="text" name="<%=inputName%>">
</form>
<script language="javascript">
<%
if(inputDate==null || inputDate.trim().length()<10){
%>
JSCalendar(document.all["<%=inputName%>"]);
<%
}else{
%>
JSCalendar(document.all["<%=inputName%>"],"<%=_year%>","<%=_month%>","<%=_date%>");
<%
}
%>
</script>
</body>
</html>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -