📄 波浪文字.htm
字号:
<html>
<head>
<title>彩灯波浪文字</title>
<style>'设置显示样式
<!--
.big1{ font-family: comic sans MS; font-size: 10pt; color: rgb(0,128,0) }
.big2{ font-family: comic sans MS; font-size: 20pt; color: rgb(0,128,0) }
.big3{ font-family: comic sans MS; font-size: 30pt; color: rgb(0,128,0) }
.big4{ font-family: comic sans MS; font-size: 40pt; color: rgb(0,128,0) }
.big5{ font-family: comic sans MS; font-size: 30pt; color: rgb(0,128,0) }
.big6{ font-family: comic sans MS; font-size: 20pt; color: rgb(0,128,0) }
.big7{ font-family: comic sans MS; font-size: 10pt; color: rgb(0,128,0) }
-->
</style>
<script LANGUAGE="VBScript">
<!--
'定义与每个文字相对应的样式
dim styleoffont(6)
styleoffont(0)="big1"
styleoffont(1)="big2"
styleoffont(2)="big3"
styleoffont(3)="big4"
styleoffont(4)="big5"
styleoffont(5)="big6"
styleoffont(6)="big7"
'定义五种颜色
dim colors(5)
colors(0)="red"
colors(1)="white"
colors(2)="green"
colors(3)="aqua"
colors(4)="lime"
colors(5)="blue"
dim j
'实现转换的过程
sub change
'定义局部变量
'i是循环变量
'tmpstyle是中间变量
dim i,tmpstyle
'利用中间变量实现七个文字的样式的循环移动
tmpstyle=styleoffont(0)
for i=0 to 5
styleoffont(i)=styleoffont(i+1)
next
styleoffont(6)=tmpstyle
'循环给七个文字赋新的样式
for i=0 to 6
document.all("font"&(i+1)).className=styleoffont(i)
next
randomize
for i=0 to 6
document.all("font"&(i+1)).style.color=colors(round(rnd()*5))
next
if j<6 then
tid=window.setInterval("change",500)
j=j+1
end if
end sub
-->
</script>
</head>
<body bgcolor="#000000" onclick="change" ID="body1">
<div align="center">
<center>
<table border="0" cellpadding="0" cellspacing="0" width="642" height="1">
<tr>
<td width="642" height="13" valign="top">
<hr noshade size="1">
</td>
</tr>
</center>
<tr>
<td width="642" height="64" valign="top">
<br><br><br><br><br>
<p align="center">
<span class="big1" id="font1">欢迎</span>
<span class="big2" id="font2">你</span>
<span class="big3" id="font3">使用</span>
<span class="big4" id="font4">VbScript</span>
<span class="big5" id="font5">编程</span>
<span class="big6" id="font6">百</span>
<span class="big7" id="font7">例</span>
</p>
</td>
</tr>
</table>
</center>
</div>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -