<HTML>
<HEAD>
<META http-equiv='Content-Type' content='text/html; charset=gb2312'>
<TITLE>非常好的生成各种按钮的页面生成器,好好研究一下吧</TITLE>
<script language="javascript">
<!--Hide
//timer
speed = 10;
//Array to make Objects
Imagi = new Array();
//numbers of Link
no_of_images = 0;
currentImage = -1;
function checkBrowser() {
var bname = navigator.appName;
var ver = parseInt(navigator.appVersion);
if (bname == "Netscape" && ver >= 3 || bname == "Microsoft Internet Explorer" && ver >= 4)
;
else {
alert('You need Netscape Navigator 3 and above or Microsoft Internet Explorer 4 and above')
}
}
checkBrowser();
//The Image Object
function ImageObject(Name, OffSrcPro, OffSrc, OnSrcPro, OnSrc, Width, Height, Alt, Border, URL, LinkTarget) {
this.Name = Name;
this.OffSrcPro = OffSrcPro;
this.OffSrc = OffSrc;
this.OnSrcPro = OnSrcPro;
this.OnSrc = OnSrc;
this.Width = Width;
this.Height = Height;
this.Alt = Alt;
this.Border = Border;
this.URL = URL;
this.LinkTarget = LinkTarget;
this.length = 11;
}
function headerSelect(grut, grutv) {
if (grut.options[0].selected) {
grutv.value = "";
}
else {
for (var y=0; y < grut.length; y++) {
if (grut.options[y].selected) {
grutv.value = "";
grutv.value += grut.options[y].text;
}
}
}
}
//Function Performing Form Validation
function checkMe(Me) {
with(Me) {
SrcBox1.focus();
SrcBox1.blur();
SrcBox2.focus();
SrcBox2.blur();
if (URLBox.value == "http://" || URLBox.value == "") {
alert("连接的URL没有设置");
URLBox.focus();
return false;
}
if (SrcBox1.value == "") {
alert("MouseOut图片尚未设置");
SrcBox1.focus();
return false;
}
if (SrcBox2.value == "") {
alert("MouseOver图片尚未设置");
SrcBox2.focus();
return false;
}
if (NameBox.value == "") {
alert("图片尚未命名");
NameBox.focus();
return false;
}
return true;
}
}
function checkAndShow() {
with(window.document.mouseOverForm.Images) {
if (options.length != 0) {
for(var i=0; i < options.length; i++) {
if (options[i].selected) {
with(window.document.mouseOverForm) {
URLBox.value = Imagi[i].URL;
TargetBox.value = Imagi[i].LinkTarget;
HeadSrc1.value = Imagi[i].OffSrcPro;
HeadSrc2.value = Imagi[i].OnSrcPro;
SrcBox1.value = Imagi[i].OffSrc;
SrcBox2.value = Imagi[i].OnSrc;
NameBox.value = Imagi[i].Name;
BorderBox.value = Imagi[i].Border
AltBox.value = Imagi[i].Alt;
WidthBox.value = Imagi[i].Width;
HeightBox.value = Imagi[i].Height;
currentImage = i;
if (HeadSrc1.value == "file:///")
Header1.options[1].selected = true;
else if (HeadSrc1.value == "http://")
Header1.options[2].selected = true;
else if (HeadSrc1.value == "")
Header1.options[0].selected = true;
if (HeadSrc2.value == "file:///")
Header2.options[1].selected = true;
else if (HeadSrc2.value == "http://")
Header2.options[2].selected = true;
else if (HeadSrc2.value == "")
Header2.options[0].selected = true;
}
}
}
}
}
}
function insertItem() {
with(window.document.mouseOverForm) {
if (checkMe(window.document.mouseOverForm)) {
Imagi[no_of_images] = new ImageObject(NameBox.value, HeadSrc1.value, SrcBox1.value, HeadSrc2.value, SrcBox2.value, WidthBox.value, HeightBox.value, AltBox.value, BorderBox.value, URLBox.value, TargetBox.value);
Images.length += 1;
Images.options[Images.length - 1].text = Imagi[no_of_images].Name;
++no_of_images;
CleanBoxes(window.document.mouseOverForm);
CleanBoxes(window.document.mou�
没有合适的资源?快使用搜索试试~ 我知道了~
网页特效实例 代码简单
共5个文件
html:5个
需积分: 10 8 下载量 174 浏览量
2009-04-24
17:30:27
上传
评论
收藏 12KB RAR 举报
温馨提示
网页特效实例 特效 实例,代码简单 网页特效实例 特效 实例,代码简单 网页特效实例 特效 实例,代码简单
资源推荐
资源详情
资源评论
收起资源包目录
.rar (5个子文件)
网页特效
十道选择题,你自己选择,自动给出成绩_webasp.html 11KB
一个经典的下拉框三级联动,并链接到相应站点_webasp.html 8KB
非常好的生成各种按钮的页面生成器,好好研究一下吧_webasp.html 49KB
四道题,查看成绩时弹出窗口,给出成绩并且给出正确答案_webasp.html 6KB
新建 文本文档.html 763B
共 5 条
- 1
资源评论
wuxian0106
- 粉丝: 12
- 资源: 14
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功