CNET中国旗舰网站

ZDNet China | CNET科技资讯网 | 政府采购 | 行业网站联盟





 
标题: [转贴] document.getElementById只在ie7执行,opera\flock均不执行,亦无错误提示
mz89757053
灵玉会员
Rank: 8Rank: 8



UID 304999
精华 0
积分 6713
帖子 8340
威望 0
ZD币 1000 元
阅读权限 180
注册 2008-3-10
状态 离线
  楼主
发表于 2008-4-23 13:30  资料  个人空间  短消息  加为好友 
开发者在线

document.getElementById只在ie7执行,opera\flock均不执行,亦无错误提示

<form   action=""   method="post"     name="loginform"   id="loginform">   
  <div   id="getcodes"   align="center"><%=getcode%></div>   
  </form>   
   
  Function   getcode()   
                  getcode   =   "<img   src=""inc/code.asp""   height=""15""     alt=""验证码""   />  <a   getanothercode();   return   false""   href=""#"">换一个</a>"   
  End   Function   
   
  js:   
  //更换验证码   
  function   getanothercode(){   
  var   insertdata='<img   src="inc/code.asp"   height="15"   alt="验证码"/>  <a      href="inc/code.asp">换一个</a>';   
  document.getElementById('getcodes').innerHTML=insertdata;   
  }




顶部
热点频道推荐: C/S开发| 数据库| WEB开发| 嵌入式| 项目管理|
 



当前时区 GMT+8, 现在时间是 2009-1-10 12:10

  Powered by Discuz! 5.5.0 © 2001-2007 Comsenz Inc.
Processed in 0.061817 second(s), 3/3 queries

清除 Cookies - 联系我们 - ZDNetChina中文社区 - 无图版