Internet | page | page
1. text box Input Restrictions
Implementation limit input large, lowercase English, digital, floating-point decimal, date, Chinese, some English, some Chinese and many other functions. Add it directly to the HTML code to use it.
lowercase English:
Onpaste = "Return Reginput (this,/^[a-z]*$/, Window.clipboardData.getData (' Text ')")
OnDrop = "Return Reginput (this,/^[a-z]*$/, Event.dataTransfer.getData (' Text ')")
Style= "Ime-mode:disabled"
>
Capital English:
Onpaste = "Return Reginput (this,/^[a-z]*$/, Window.clipboardData.getData (' Text ')")
OnDrop = "Return Reginput (this,/^[a-z]*$/, Event.dataTransfer.getData (' Text ')")
style= "Ime-mode:disabled" >
Any number:
Onpaste = "Return Reginput (this,/^[0-9]*$/, Window.clipboardData.getData (' Text ')")
OnDrop = "Return Reginput (this,/^[0-9]*$/, Event.dataTransfer.getData (' Text ')")
Style= "Ime-mode:disabled"
>
Limited to 2 decimal places:
Onpaste = "Return Reginput" (this,/^\d*\.? \d{0,2}$/, Window.clipboardData.getData (' Text ')) "
OnDrop = "Return Reginput" (this,/^\d*\.? \d{0,2}$/, Event.dataTransfer.getData (' Text ')) "
Style= "Ime-mode:disabled"
> such as: 123.12
Date:
String.fromCharCode (Event.keycode)) "
Onpaste = "Return Reginput" (This,/^\d{1,4} ([-\/] (\d{1,2} ([-\/] (\d{1,2})?)? $/,
Window.clipboardData.getData (' Text ')) "
OnDrop = "Return Reginput" (This,/^\d{1,4} ([-\/] (\d{1,2} ([-\/] (\d{1,2})?)? $/,
Event.dataTransfer.getData (' Text ')) "
Style= "Ime-mode:disabled"
> such as: 2002-9-29
Any Chinese:
Onpaste = "Return Reginput (this,/^[\u4e00-\u9fa5]*$/, Window.clipboardData.getData (' Text ')")
OnDrop = "Return Reginput (this,/^[\u4e00-\u9fa5]*$/, Event.dataTransfer.getData (' Text ')")
>
Part English:
Onpaste = "Return Reginput (this,/^[a-e]*$/, Window.clipboardData.getData (' Text ')")
OnDrop = "Return Reginput (this,/^[a-e]*$/, Event.dataTransfer.getData (' Text ')")
Style= "Ime-mode:disabled"
> Scope: a,b,c,d,e
Part Chinese:
Onpaste = "Return Reginput (this,/^[1,234,567,890]*$/, Window.clipboardData.getData (' Text ')")
OnDrop = "Return Reginput (this,/^[1,234,567,890]*$/, Event.dataTransfer.getData (' Text ')")
> Scope: 1,234,567,890
2. Can not expand the right button, can not select all, can not replicate the implementation
Onkeypress= "Window.event.returnvalue=false"
onkeyup= "Window.event.returnvalue=false"
Ondragstart= "Window.event.returnvalue=false"
onselectstart= "Event.returnvalue=false" >
...
3. Prevent page body content from being selected
Onselectstart = "return false" onselect= "Document.selection.empty ()"
Oncopy= "Document.selection.empty ()" Onbeforecopy= "return
False ">
4. Avoid others to put the Web page in the frame
5. Forbidden to view source code
6. Close the Input method
7. Prohibit picture downloading
At the end of here add:
Oncontextmenu= ' return false ' ondragstart= ' return false ' onselectstart= ' return
False "scroll=" Auto "
8. Prohibit caching
Add in head: