报课、招生咨询电话:010-51268840/41

首页 > 计算机考试 > 水平考试 >
→论坛登陆 用户名  密码  
网页特效:很Cool页面转换效果

作者: 发布时间:2008-06-23 13:58:12 来源:育路计算机考试
脚本说明:

  第一步:把如下代码加入<body>区域中

  <script LANGUAGE="Javascript">
  <!--
  // 过渡的速度
  var pause=50
  var widthstep=10
  // 效果的色彩
  var curtaincolor1="FFFF00"
  // 右
  var curtaincolor2="EE8800"
  // 下
  var curtaincolor3="EE8800"
  // 左
  var curtaincolor4="FFFF00"
  var screenheight
  var screenwidth
  var heightstep
  var maxmove=0
  var timer
  var url
  var curtaincontent1=""
  var curtaincontent2=""
  var curtaincontent3=""
  var curtaincontent4=""
  function init() {
   if (document.all) {
    screenwidth=document.body.clientWidth
    screenheight=document.body.clientHeight
    curtaincontent1="<table cellpadding=0 cellspacing=0 width='"+screenwidth+"' height='"+screenheight+"'><tr><td bgcolor='"+curtaincolor1+"'> </td></tr></table>"
    curtaincontent2="<table cellpadding=0 cellspacing=0 width='"+screenwidth+"' height='"+screenheight+"'><tr><td bgcolor='"+curtaincolor2+"'> </td></tr></table>"
    curtaincontent3="<table cellpadding=0 cellspacing=0 width='"+screenwidth+"' height='"+screenheight+"'><tr><td bgcolor='"+curtaincolor3+"'> </td></tr></table>"
    curtaincontent4="<table cellpadding=0 cellspacing=0 width='"+screenwidth+"' height='"+screenheight+"'><tr><td bgcolor='"+curtaincolor4+"'> </td></tr></table>"
    curtain1.innerHTML=curtaincontent1
    curtain2.innerHTML=curtaincontent2
    curtain3.innerHTML=curtaincontent3
    curtain4.innerHTML=curtaincontent4
    heightstep=Math.round(widthstep/screenwidth*screenheight)
   }
   if (document.layers) {
    screenwidth=window.innerWidth
    screenheight=window.innerHeight
    curtaincontent1="<table cellpadding=0 cellspacing=0 width='"+screenwidth+"' height='"+screenheight+"'><tr><td bgcolor='"+curtaincolor1+"'>&nbsp;</td></tr></table>"
    curtaincontent2="<table cellpadding=0 cellspacing=0 width='"+screenwidth+"' height='"+screenheight+"'><tr><td bgcolor='"+curtaincolor2+"'>&nbsp;</td></tr></table>"
    curtaincontent3="<table cellpadding=0 cellspacing=0 width='"+screenwidth+"' height='"+screenheight+"'><tr><td bgcolor='"+curtaincolor3+"'>&nbsp;</td></tr></table>"
    curtaincontent4="<table cellpadding=0 cellspacing=0 width='"+screenwidth+"' height='"+screenheight+"'><tr><td bgcolor='"+curtaincolor4+"'>&nbsp;</td></tr></table>"
    document.curtain1.document.write(curtaincontent1)
    document.curtain1.document.close()
    document.curtain2.document.write(curtaincontent2)
    document.curtain2.document.close()
    document.curtain3.document.write(curtaincontent3)
    document.curtain3.document.close()
    document.curtain4.document.write(curtaincontent4)
    document.curtain4.document.close()
    heightstep=Math.round(widthstep/screenwidth*screenheight)
   }
  }
  function openpage(thisurl) {
   url=thisurl
   if (document.all) {
    document.all.curtain1.style.posTop=-screenheight
    document.all.curtain1.style.posLeft=0
    document.all.curtain2.style.posTop=0
    document.all.curtain2.style.posLeft=screenwidth
    document.all.curtain3.style.posTop=screenheight
    document.all.curtain3.style.posLeft=0
    document.all.curtain4.style.posTop=0
    document.all.curtain4.style.posLeft=-screenwidth
    document.all.curtain1.style.visibility="VISIBLE"
    document.all.curtain2.style.visibility="VISIBLE"
    document.all.curtain3.style.visibility="VISIBLE"
    document.all.curtain4.style.visibility="VISIBLE"
    movecurtains()
   }

 if (document.layers) {
    document.curtain1.top=-screenheight
    document.curtain1.left=0
    document.curtain2.top=0
    document.curtain2.left=screenwidth
    document.curtain3.top=screenheight
    document.curtain3.left=0
    document.curtain4.top=0
    document.curtain4.left=-screenwidth
    document.curtain1.visibility="VISIBLE"
    document.curtain2.visibility="VISIBLE"
    document.curtain3.visibility="VISIBLE"
    document.curtain4.visibility="VISIBLE"
    movecurtains()
   }
  }
  function movecurtains() {
   if (maxmove<=screenwidth/2) {
    if (document.all) {
     document.all.curtain1.style.posTop+=heightstep
     document.all.curtain2.style.posLeft-=widthstep
     document.all.curtain3.style.posTop-=heightstep
     document.all.curtain4.style.posLeft+=widthstep
    }
    if (document.layers) {
     document.curtain1.top+=heightstep
     document.curtain2.left-=widthstep
     document.curtain3.top-=heightstep
     document.curtain4.left+=widthstep
    }
    maxmove+=widthstep
    var timer=setTimeout("movecurtains()",pause)
   }
   else {
    clearTimeout()
    document.location.href=url
   }
  }
  // - End of Javascript - -->
  </script>
  <STYLE>
  .curtain {
    position:absolute;
   visibility:hidden;
  }
  </STYLE>
  <DIV ID="deletethisblock" class="redirstyle" style="position:absolute;left:10px;top:10px;color:000000;font-family:"宋体";font-size:9pt">
  <a href="javascript:openpage('http://www.csai.cn/')">看看效果吧!!</a>
  </DIV>
  <DIV ID="curtain1" class="curtain"></DIV>
  <DIV ID="curtain2" class="curtain"></DIV>
  <DIV ID="curtain3" class="curtain"></DIV>
  <DIV ID="curtain4" class="curtain"></DIV>

  第二步:把<body>中的内容改为:

  <body bgcolor="#fef4d9" onLoad="init()" style="width:100%;overflow-x:hidden;overflow-y:hidden">

    育路网

 
 
                                        
评论】【加入收藏夹】【 】【打印】【关闭
育路网2007年夏令营联展
 更多有关新闻:
 
·[考试动态2008年医师资格考试网上报名须知 ·[考试动态2008年医师资格考试3月10日开始网
·[考试动态卫生部医师资格考试委员会公告 ·[考试动态2008年医师考试于9月20至21进行
·[考试动态关于北京考区2008年度国家医师资 ·[考试动态崇文区卫生局关于北京考区2008年
·[考试动态丰台区卫生局关于北京考区2008年 ·[考试动态2008年上海市医师资格考试(考区
·[考试动态2008年医师资格考试(天津考区) ·[考试动态惠州市卫生局关于2008医师资格考
·[考试动态无锡市关于2008年医师资格考试网 ·[考试动态关于珠海市2008年医师资格考试的
·[考试动态韶关市关于2008年医师资格考试网 ·[考试动态深圳市关于2008年医师资格考试深
·[考试动态杭州市卫生局关于2008年医师资格 ·[考试动态丽水市关于2008年医师资格考试报
发表评论
用户名: 密码:
验证码: 匿名发表
课程搜索:
选择分类:
课程关键字:
课程 学校
 2008年首都高校秋季招生
北京理工大学2008年招生简章
北京文理研修学院2008年招生简章
北京建设大学2008年招生简章
北京中山学院2008年招生简章
北京城市学院2008年招生简章
培黎职业学院2008年招生简章
北京金融学院2008年招生简章
北京吉利大学2008年招生简章
北方工商管理学院2008年招生简章
 本周推荐课程
·初中起点雅思半年脱产 ·启德雅思6分冲刺课程
·新概念1+2册慢速精讲课 ·环球新托福100分强化
·北文王长喜四级强化班 ·英语四、六级培训课程
·海文考研数学课程 ·海文考研英语课程
·北大企业管理高级研修班 ·清华企业领导人研修班
·中美高中生交换项目 ·北工大中加学院2+2本科
·劳动和社会保障部物流师 ·物业管理师职业培训
·市场营销经理国际资格 ·现场管理实务培训
清华大学留学
中法管理硕士预科班
课程咨询热线:010-51268840 51268841
 最新新闻
·教育部考试中心:托福下半年增四次网考
·美国SAT将可多次重考争取最好成绩 两年内实行
·河北08年高考分数线初定一本文科537理科552
·公务员辅导:申论命题和考试的变化规律
·公务员辅导:申论命题和考试的变化规律
·新疆公务员、工作人员考试报名结束
·新疆公务员、工作人员考试报名结束
·山西省国家行政机关2008年考试录用公务员报名
·2008年山西省公务员考试考前辅导长治招生简章
·“范跑跑”成公务员面试成考题
 育路社区            进入>>
 
学员报名服务中心: 北京北三环西路32号恒润中心1806(交通位置图
咨询电话:北京- 010-51268840/41 传真:010-51418040 上海-021-64392659、64397431
育路网-中国新锐教育社区: 北京站 | 上海站 | 郑州站| 武汉站
本站法律顾问: 邱清荣律师
北京育路互联科技有限公司版权所有 | 京ICP备05012189号