?? cls_script2.1.asp
字號:
<%
'文件功能:客戶端操作公用Script函數(shù)
'文件版本:2.1
%>
<!--
*********************************
*********************************
*** ***
*** 客戶端腳本 ***
*** ***
*********************************
*********************************
-->
<SCRIPT LANGUAGE="javascript">
<!--********************************************************************************-->
function ConvertToDate(pStr_Year,pStr_Month,pStr_Day){
//功能:轉換為日期
//參數(shù):年、月、日
//返回:日期
var Int_Year,Int_Month,Int_Day
Int_Year = Number(pStr_Year)
Int_Month = Number(pStr_Month)
Int_Day = Number(pStr_Day)
if (Int_Year !=0 && Int_Month !=0 && Int_Day !=0) {
return Int_Year+"-" + Int_Month + "-" + Int_Day
} else {
return ""
}
}
<!--********************************************************************************-->
function ShowMess(pStr_Type,pStr_Mess){
//功能:顯示信息
//參數(shù):信息類型,信息內容
//返回:無
switch (pStr_Type) {
default:
alert(pStr_Mess);
};
}
<!--********************************************************************************-->
function WindowBack(){
//功能:返回上頁
//參數(shù):無
//返回:無
window.history.back();
}
<!--********************************************************************************-->
function WindowBackAndReload(){
//功能:返回上頁并刷新
//參數(shù):無
//返回:無
WindowBack()
window.open("../Common/Opr_WindowBackAndReload2.1.asp","_blank","top=1000,toolbar=no,menubar=no,location=no");
}
<!--********************************************************************************-->
function WindowClose(pStr_URL){
//功能:關閉窗口
//參數(shù):無
//返回:無
window.close();
}
<!--********************************************************************************-->
function WindowFrame(pStr_URL,pStr_FrameName){
//功能:替換當前窗口某頁框的網(wǎng)址
//參數(shù):網(wǎng)址
//返回:無
var Str_Date=new Date()
Int_Pos = pStr_URL.indexOf("?");
if (Int_Pos > 0 ){
pStr_URL = pStr_URL + "&urltime=" + Str_Date;
} else {
pStr_URL = pStr_URL + "?urltime=" + Str_Date;
}
window.open(pStr_URL,pStr_FrameName);
}
<!--********************************************************************************-->
function WindowPrint() {
//功能:打印當前窗口
//參數(shù):無
//返回:無
function stopError() {
return true;
};
window.onerror = stopError;
if (window.print) {
eval("self.print()");
} else {
if (document.all) {
var OLECMDID_PRINT = 6;
var OLECMDEXECOPT_DONTPROMPTUSER = 2;
var OLECMDEXECOPT_PROMPTUSER = 1;
var WebBrowser = "<OBJECT ID=\"WebBrowser1\" WIDTH=0 HEIGHT=0 CLASSID=\"CLSID:8856F961-340A-11D0-A96B-00C04FD705A2\"></OBJECT>";
document.body.insertAdjacentHTML("beforeEnd", WebBrowser);
WebBrowser1.ExecWB(OLECMDID_PRINT, OLECMDEXECOPT_PROMPTUSER);
WebBrowser1.outerHTML = "";
}
}
}
<!--********************************************************************************-->
function WindowReplace(pStr_URL){
//功能:替換當前窗口的網(wǎng)址
//參數(shù):網(wǎng)址
//返回:無
window.location.replace(pStr_URL);
}
</SCRIPT>
<!--********************************************************************************-->
<%
' *********************************
' *********************************
' *** ***
' *** 服務器腳本 ***
' *** ***
' *********************************
' *********************************
%>
<%
'********************************************************************************
function ShowMess(pStr_Type,pStr_Mess)
'功能:顯示信息
'參數(shù):信息類型,信息內容
'返回:無
pStr_Mess = replace(pStr_Mess,vbCrlf,"\n")
pStr_Mess = replace(pStr_Mess,chr(13),"\n")
%>
<SCRIPT LANGUAGE="javascript">
ShowMess("<% Response.write pStr_Type %>","<% Response.write pStr_Mess %>");
</SCRIPT>
<%
end function
'********************************************************************************
function WindowBack()
'功能:返回上頁
'參數(shù):無
'返回:無
%>
<SCRIPT LANGUAGE="javascript">
WindowBack();
</SCRIPT>
<%
response.end
end function
'********************************************************************************
function WindowBackAndReload()
'功能:返回上頁并刷新
'參數(shù):無
'返回:無
%>
<SCRIPT LANGUAGE="javascript">
WindowBackAndReload();
</SCRIPT>
<%
response.end
end function
'********************************************************************************
function WindowClose()
'功能:關閉窗口
'參數(shù):無
'返回:無
%>
<SCRIPT LANGUAGE="javascript">
WindowClose();
</SCRIPT>
<%
response.end
end function
'********************************************************************************
function WindowFrame(pStr_URL,pStr_FrameName)
'功能:替換當前窗口某頁框的網(wǎng)址
'參數(shù):網(wǎng)址
'返回:無
%>
<SCRIPT LANGUAGE="javascript">
WindowFrame("<% Response.write pStr_URL%>","<% Response.write pStr_FrameName%>");
</SCRIPT>
<%
end function
'********************************************************************************
function WindowReplace(pStr_URL)
'功能:替換當前窗口的網(wǎng)址
'參數(shù):網(wǎng)址
'返回:無
%>
<SCRIPT LANGUAGE="javascript">
WindowReplace("<% Response.write pStr_URL%>");
</SCRIPT>
<%
response.end
end function
%>
<LINK REL="stylesheet" HREF="<% Response.write GetStyleFile()%>">
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -