让网页上的字符掉下来


看 我 们 一 个 一 个 掉 下 来 !
将下代码copy入你网页的和中的合适地方即可:
0) && (parseInt(navigator.appVersion.substring(ms+5, ms+6)) >= 4) if(!ie4) { if((navigator.appName == "Netscape") && (parseInt(navigator.appVersion.substring(0, 1)) >= 4)) { for (index=document.layers.length-1; index >= 0; index--) { layer=document.layers[index] if (layer.left==10000) layer.left=0 } } return } for (index=document.all.length-1; index >= document.body.sourceIndex; index--) { el = document.all[index] animation = el.getAttribute(dynamicanimAttr, false) if(null != animation) { if(animation == "dropword" || animation == "flyTopRightword" || animation == "flyBottomRightword") { ih = el.innerHTML outString = "" i1 = 0 iend = ih.length while(true) { i2 = startword(ih, i1) if(i2 == -1) i2 = iend outword(ih, i1, i2, false, "") if(i2 == iend) break i1 = i2 i2 = endword(ih, i1) if(i2 == -1) i2 = iend outword(ih, i1, i2, true, animation) if(i2 == iend) break i1 = i2 } document.all[index].innerHTML = outString document.all[index].style.posLeft = 0 document.all[index].setAttribute(dynamicanimAttr, null) } if(animation == "zoomIn" || animation == "zoomOut") { ih = el.innerHTML outString = "" outString += ih.substring(i1, i2) if(dyn) outString += "" } function animate() { el = animateElements[currentElement] animation = el.getAttribute(dynamicanimAttr, false) step++ if(animation == "spiral") { steps = stepsSpiral v = step/steps rf = 1.0 - v t = v * 2.0*Math.PI rx = Math.max(Math.abs(el.initLeft), 200) ry = Math.max(Math.abs(el.initTop), 200) el.style.posLeft = Math.ceil(-rf*Math.cos(t)*rx) el.style.posTop = Math.ceil(-rf*Math.sin(t)*ry) } else if(animation == "zoomIn") { steps = stepsZoom el.style.fontSize = Math.ceil(50+50*step/steps) + "%" el.style.posLeft = 0 } else if(animation == "zoomOut") { steps = stepsZoom el.style.fontSize = Math.ceil(100+200*(steps-step)/steps) + "%" el.style.posLeft = 0 } else { steps = stepsFly if(animation == "dropword" || animation == "flyTopRightword" || animation == "flyBottomRightword") steps = stepsword dl = el.initLeft / steps dt = el.initTop / steps el.style.posLeft = el.style.posLeft - dl el.style.posTop = el.style.posTop - dt } if (step >= steps) { el.style.posLeft = 0 el.style.posTop = 0 currentElement++ step = 0 } if(currentElement
把你HTML文件的改为如下:
把下面代码copy入你HTML文件的和中即可:
文字内容
注意:汉字间加一个空格,汉字就会一个个地掉下来,否则会一起掉下来.
旋转的文本
第一步:把下面的脚本插入与之间:
.fly {
POSITION: absolute; VISIBILITY: hidden; Z-INDEX: 2
}
.LOGO {
LEFT: 231px; POSITION: absolute; TOP: 130px; VISIBILITY: visible; Z-INDEX: 1
}
.desc {
COLOR: #006600; FONT-FAMILY: 宋体; LEFT: 235px; POSITION: absolute; TEXT-ALIGN: center; TOP: 355px; VISIBILITY: hidden; WIDTH: 100px
}
a:active { font-family: "宋体"; font-size: 9pt; color: #006600; text-decoration: none}
a:hover { font-family: "宋体"; font-size: 9pt; color: #00FF00; text-decoration: underline}
a:link { font-family: "宋体"; font-size: 9pt; color: #006600; text-decoration: none}
a:visited { font-family: "宋体"; font-size: 9pt; color: #006600; text-decoration: none}
body { font-size: 9pt; color: #006600}
function showObject(object) {
object.visibility = VISIBLE;
}
function hideObject(object) {
object.visibility = HIDDEN;
}
function slideLOGO(from, to) {
if (from < to) {
company.top = (from += 10);
setTimeout('slideLOGO(' + from + ',' + to + ')', 75);
}
else initObjects();
}
function rotateObjects() {
for (var i = 0; i < pos.length; i++) {
pos[i] += inc; objects[i].visibility = 'visible';
objects[i].left = (r * Math.cos(pos[i])) + xoff
objects[i].top = (r * Math.sin(pos[i])) + yoff;
}
rotateTimer = setTimeout("rotateObjects()", 75);
}
function initObjects() {
objects = new Array(fly1, fly2, fly3, fly4, fly5);
pos = new Array();
pos[0] = 0;
for (var i = 1; i < objects.length; i++) {
pos[i] = parseFloat(pos[i - 1] + ((2 * pi) / objects.length));
}
rotateObjects();
}
var objects;
var pos;
var r = 148; // 旋转的半径
var xoff = 260; // 旋转的X座标
var yoff = 150; // Y座标
var pi = Math.PI; //
var inc = pi / 180;
var objects;
var pos;
function high(which2){
theobject=which2
highlighting=setInterval("highlightit(theobject)",50);
showObject(desc6);
}
function low(which2){
clearInterval(highlighting)
which2.filters.alpha.opacity=70;
hideObject(desc6);
}
function highlightit(cur2){
if (cur2.filters.alpha.opacity<100)
cur2.filters.alpha.opacity+=3
else if (window.highlighting)
clearInterval(highlighting)
}
第二步:把下面的脚本插入与之间:
蓝色沙漠 //以下为旋转的文本
链接2
链接3
链接4
链接5

蓝色沙漠---技术中心
DHTML之旋转的文本
这里也可以是图象!
蓝色沙漠 //以下改成你的链接说明
链接说明2
链接说明3
链接说明4
链接说明5
var isNS = (navigator.appName == "Netscape" && parseInt(navigator.appVersion) >= 4);
var HIDDEN = (isNS) 'hide' : 'hidden';
var VISIBLE = (isNS) 'show' : 'visible';
var fly1 = (isNS) document.fly1 : document.all.fly1.style;
var fly2 = (isNS) document.fly2 : document.all.fly2.style;
var fly3 = (isNS) document.fly3 : document.all.fly3.style;
var fly4 = (isNS) document.fly4 : document.all.fly4.style;
var fly5 = (isNS) document.fly5 : document.all.fly5.style;
var company = (isNS) document.company : document.all.company.style;
var desc1 = (isNS) document.desc1 : document.all.desc1.style;
var desc2 = (isNS) document.desc2 : document.all.desc2.style;
var desc3 = (isNS) document.desc3 : document.all.desc3.style;
var desc4 = (isNS) document.desc4 : document.all.desc4.style;
var desc5 = (isNS) document.desc5 : document.all.desc5.style;
slideLOGO(-200, 130); //下降开始与结束的位置

本文作者:



相关阅读:
php设计模式 Template (模板模式)
一个多次搜索+多次传值的解决方案
jQuery 加上最后自己的验证
学习ExtJS Panel常用方法
不要忘了为你的JavaScript命名
javascript实例 “飞舞”特效
生成目录树结构的类
脚本编程 4 驱动器
Atlas中有趣且无用的功能:Sys.UI.Window类
IE bug table元素的innerHTML
Asp.Net 和 AJAX.Net 的区别
array_multisort实现PHP多维数组排序示例讲解
CSS三层布局模型
IIS6架设网站常见问题及症状举例
快速导航

Copyright © 2016 phpStudy |