易截截图软件、单文件、免安装、纯绿色、仅160KB

解决Firefox 下F5和IE下F5 不一致的javascript 脚本.

解决Firefox 下F5和IE下F5 不一致的javascript 脚本.
var check=function(e)
 {
  e=e||window.event;
  //alert(e.which||e.keyCode);
  if((e.which||e.keyCode)==116)
  {
   if(e.preventDefault)
   { e.preventDefault();}
   else
   {
    event.keyCode = 0;
    e.returnValue=false;
   }  
            window.location.href = this.location.href;
  }
 }
 if(document.addEventListener){
  document.addEventListener("keydown",check,false);
 }
 else{
  document.attachEvent("onkeydown",check);
 }


相关文档:

107条javascript常用语句

1. document.write( " "); 输出语句
2.JS中的注释为//
3.传统的HTML文档顺序是:document- >html- >(head,body)
4.一个浏览器窗口中的DOM顺序是:window- >(navigator,screen,history,location,document)
5.得到表单中元素的名称和值:document.getElementById( "表单中元素的ID號 ").name(或valu ......

JavaScript中 的倒计时

<html>
<head>
<title></title>
</head>
<body>
<form id=aa name=aa>
<input type=button value="同意(10)" id=a1 disabled="disabled">
</form>
</body>
</html>
<script>
var num=10;
window.setTimeout("aa()",1000);
function ......

javascript实现对文件上传类型的限制

注: http://www.java114.com/277/content4355.html
 
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<TITLE> upload </TITLE>
<META NAME="Generator" CONTENT="EditPlus">
<META NAME="Author" CONTENT="">
<META NAME ......

JavaScript 如何弹出一个对话框窗口

//定义要打开的对话框页面的地址 一般用action跳转要写明action的地址,如果需要参数,则在后面拼接
var urlDialog = "grpBlackWhiteManageAction.do?act=choiceMessageModel&GrpBWhiteListLevel=0";
//定义要弹出的对话框的模式,dialogWidth宽,dialogHeight高 等等
 var style = "dialogWidth=600px;dialogH ......

使用javascript打开模态对话框

1. 标准的方法
<mce:script type="text/javascript"><!--

function openWin(src, width, height, showScroll){
window.showModalDialog (src,"","location:No;status:No;help:No;dialogWidth:"+width+";dialogHeight:"+height+";scroll:"+showScroll+";");
}
// --></mce:script> &n ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号