?? 二次開發(fā)參考代碼.txt
字號:
權限代碼 if WS_S.MemberPriv("WS_PublicAffairsBookView")<>1 then response.Write "<script>alert('對不起,您的權限不夠!');window.close();</script>":response.end
if WS_S.MemberPriv("WS_PublicAffairsBookView")<>1 then HX_GoBack "對不起,您的權限不夠!",""
日期設置代碼<!--#INCLUDE FILE="../HXINCLUDE/SelectDate.asp"-->
<input type="text" name="Date1" size=10 readonly> <input onclick="popUpcalendar(this, form1.Date1, 'yyyy/mm/dd')" type="button" value="選擇" title="選擇開始時間">
格式化時間函數(shù) formatdatetime
只允許輸入數(shù)字 style="ime-mode:disabled" onKeyPress="event.returnValue=IsDigit();"
關閉輸入法 style="ime-mode:disabled"
組建日期 DateSerial(cint(request("yy1")),cint(request("mm1")),cint(1))
查詢沒有重復的記錄 distinct select distinct username from [user]
js代碼調用 <script src="../HXinclude/HX_Function.js"></script>
添加修改數(shù)據(jù)后代碼:
response.write "<script>window.opener.location.reload();if(!confirm('是否繼續(xù)添加?')) window.close();else location.href='weburlsearchadd.asp';</script>"
response.end
response.write "<script>window.opener.location.reload();if(confirm('是否繼續(xù)添加?')) {location.href='WorkFlowAddType.asp';}else {location.href='WorkFlowType.asp';window.close();}</script>"
response.end
response.write "<script>if(confirm('修改成功!\n是否關閉此窗口?')) {window.close();window.opener.location.reload();}else {location.href='carmodify.asp?WS_MAID="&WS_MAID&"';}</script>"
response.end
色調代碼: D4D0C8 A1BBE0
<a href="javascript:" onclick="showModalDialog('../HXEditor/table.htm', '', 'dialogWidth:25em; dialogHeight:17em; status:0;help:0');"
輸入用戶信息代碼: Call WS_S.HX_OutUserInfo(loginuid):response.Write Outdepartment&OutAppointmen&OutName
改變表格行色調: onmouseover=javascript:this.bgColor='#F9F8F2' onmouseout=javascript:this.bgColor='#ffffff'
自動選擇文本框: onFocus=this.select() onMouseOver=this.focus()
選擇用戶代碼: <input onclick="openwin(510,500,'../HXinclude/HX_Checkuser.asp?checkuser=OfficeManage')" type="button" value="選擇" class="bdlogin">
輸出表記錄代碼:
if rs.recordcount<=0 then
response.Write "<tr><td colspan=5 bgcolor=ffffff height=25 align=center>暫無記錄!</td></tr>"
else
rs.PageSize =15 '每頁記錄條數(shù)
iCount=rs.RecordCount '記錄總數(shù)
iPageSize=rs.PageSize
maxpage=rs.PageCount
page=request("page")
if Not IsNumeric(page) or page="" then
page=1
else
page=cint(page)
end if
if page<1 then
page=1
elseif page>maxpage then
page=maxpage
end if
rs.AbsolutePage=Page
if page=maxpage then
x=iCount-(maxpage-1)*iPageSize
else
x=iPageSize
end if
ii=0
do while not rs.EOF
%>
<tr <%if ii mod 2=0 then response.write "bgcolor='#FFFFFF'" else response.write "bgcolor='#f1f1f1'"%>>
<%ii=ii+1
if ii>=rs.PageSize then Exit Do
rs.movenext
loop
call WS_S.PageControl(iCount,maxpage,page,"border=0 align=right","<p align=right>",5)
end if
call WS_S.HX_RSClose(rs)
%>
關閉表對象代碼 call WS_S.HX_RSClose(rs)
菜單權限 if WS_S.MemberPriv("WS_DeskMyoffice")=1 then response.write "<tr><td width=""100%"" align=""center"" class=""include1""><a href=""HXPersonalOffice/index.asp"" onclick=""top.right.location='HXPersonalOffice/MyMessage.asp';""><font color=""#FFFFFF"">個人辦公</font></a></td></tr>"
禁止右鍵: <body oncontextmenu='return false' ondragstart='return false' onselectstart='return false' onkeydown='if((event.ctrlKey)||(event.keyCode==8)||(event.keyCode==116)){event.keyCode=0;return false}'>
加框代碼 <fieldset><legend> 個體內容 </legend></fieldset>
檢測木馬 WS_S.CheckDir filepath,True
if WS_S.HX_ScanFile(FileSeverPath) then
WS_S.CheckFile FileSeverPath,True
conn.execute("delete * from HX_NetDiskFolderOrFile where WS_FDID="&FileId)
HX_GoBack "對不起,您上傳的文件中含有木馬程序,所以不能上傳!",""
end if
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -