>
设为首页
>
收藏本站
>
最新电影
首页
运营资讯
今日英语
图形图像
计算机技术
Asp编程
网站结构化
资源共享
休闲娱乐
访问新站
您现在的位置:
首页
=>
后台技术
=>
脚本特效
=>
窗口特效
订阅本栏目
可以拖动的层提示框
时间: 2008-01-14 23:40:40 阅读次数:2047
可以拖动的层提示框
<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=gb2312"> <title>网页特效|www.ffasp.com 飞飞Asp乐园|---带颜色的欢迎窗口</title> </head> <body> <script language="javascript"> var IE5=(document.getElementById && document.all)? true : false; var W3C=(document.getElementById)? true: false; var currIDb=null, currIDs=null, xoff=0, yoff=0; zctr=0; totz=0; function trackmouse(evt){ if((currIDb!=null) && (currIDs!=null)){ var x=(IE5)? event.clientX+document.body.scrollLeft : evt.pageX; var y=(IE5)? event.clientY+document.body.scrollTop : evt.pageY; currIDb.style.left=x+xoff+'px'; currIDs.style.left=x+xoff+10+'px'; currIDb.style.top=y+yoff+'px'; currIDs.style.top=y+yoff+10+'px'; return false; }} function stopdrag(){ currIDb=null; currIDs=null; NS6bugfix(); } function grab_id(evt){ xoff=parseInt(this.IDb.style.left)-((IE5)? event.clientX+document.body.scrollLeft : evt.pageX); yoff=parseInt(this.IDb.style.top)-((IE5)? event.clientY+document.body.scrollTop : evt.pageY); currIDb=this.IDb; currIDs=this.IDs; } function NS6bugfix(){ if(!IE5){ self.resizeBy(0,1); self.resizeBy(0,-1); }} function incrzindex(){ zctr=zctr+2; this.subb.style.zIndex=zctr; this.subs.style.zIndex=zctr-1; } function createPopup(id, title, width, height, x , y , isdraggable, boxcolor, barcolor, shadowcolor, text, textcolor, textptsize, textfamily ){ if(W3C){ zctr+=2; totz=zctr; var txt=''; txt+='<div id="'+id+'_s" style="position:absolute; left:'+(x+10)+'px; top:'+(y+10)+'px; width:'+width+'px; height:'+height+'px; background-color:'+shadowcolor+'; filter:alpha(opacity=50); visibility:visible"> </div>'; txt+='<div id="'+id+'_b" style="border:outset '+barcolor+' 2px; position:absolute; left:'+x+'px; top:'+y+'px; width:'+width+'px; overflow:hidden; height:'+height+'px; background-color:'+boxcolor+'; visibility:visible">'; txt+='<div style="width:'+width+'px; height:16px; background-color:'+barcolor+'; padding:0px; border:1px"><table cellpadding="0" cellspacing="0" border="0" width="'+(IE5? width-4 : width)+'"><tr><td width="'+(width-20)+'"><div id="'+id+'_h" style="width:'+(width-20)+'px; height:14px; font: bold 12px sans-serif; color:'+textcolor+'"> '+title+'</div></td><td align="right"><a onmousedown="document.getElementById(\''+id+'_s\').style.display=\'none\'; document.getElementById(\''+id+'_b\').style.display=\'none\';return false"><img src="images/closeb.gif" border="0" height="15" width="15"></a></td></tr></table></div>'; txt+='<div id="'+id+'_ov" width:'+width+'px; style="margin:2px; color:'+textcolor+'; font:'+textptsize+'pt '+textfamily+';">'+text+'</div></div>'; document.write(txt); this.IDh=document.getElementById(id+'_h'); this.IDh.IDb=document.getElementById(id+'_b'); this.IDh.IDs=document.getElementById(id+'_s'); this.IDh.IDb.subs=this.IDh.IDs; this.IDh.IDb.subb=this.IDh.IDb; this.IDh.IDb.IDov=document.getElementById(id+'_ov'); if(IE5){ this.IDh.IDb.IDov.style.width=width-6; this.IDh.IDb.IDov.style.height=height-22; this.IDh.IDb.IDov.style.scrollbarBaseColor=boxcolor; this.IDh.IDb.IDov.style.overflow="auto"; }else{ this.IDh.IDs.style.MozOpacity=.5; } this.IDh.IDb.onmousedown=incrzindex; if(isdraggable){ this.IDh.onmousedown=grab_id; this.IDh.onmouseup=stopdrag; }}} if(W3C)document.onmousemove=trackmouse; if(!IE5 && W3C)window.onload=NS6bugfix; createPopup( 'box3', '欢迎光临' , 288, 90, 275, 155, true, 'FF9966' , '000000' , '800000' , '欢迎光临飞飞Asp乐园 网络因你而精彩' , 'FFFFFF' , 9 , '宋体'); </script> </body> </html>
提示:您可以先修改部分代码再运行
飞飞Asp技~术乐园
站内搜索
:
标题
内容
下一篇
关不掉的提示框
上一篇
按钮打开窗口
本栏目最新
栏目最新列表
js使用cookie设置广告出现的次数
右下角漂浮代码
自动最大话打开的页面
用Div仿showModalDialog模式菜单的效果
div对话框 麽态对话框
网站优化策划
栏目最新列表
增加网站外链的快速方法
网站上线前必做的30个检查
新的友情链接参考标准(没有google的PR情况
优化Google的AdSense广告的五个工具
王通讲SEO八大基础
站点最新
站点最新列表
微博推广的一些技巧
xhEditor v1.1.7 发布,
收集的一些轻量级非常实
50个新鲜兼容最新版本的
javascript中cookie的设
Excel中出现#VALUE!、#D
jquery插件:飞飞表情插件
十个使用HTML5开发的精彩
支持HTML5的浏览器有哪些
飞妮莫属:漫画:如何写出
历史最热10条信息
MIME介绍 及
[
1
] [
2
] [
3
]
巧用Google和迅雷来下载
Transact SQL 常
[
1
] [
2
]
VIA Rhine II Fast Ethe
电脑常用端
[
1
] [
2
] [
3
]
Do you get a kick out
十道羊皮卷 欣赏+mp3版+
每日一句:A friend and
每日一句:Theres no tu
经典__悟透JavaScript
伟哥博客
西安房产
123最新电影
三四六四
关于站点
|
免责声明
|
联系站长
|
网站地图
|
陕ICP备07002804号
WEB技术QQ交流群:72840059
©2007 ffasp.com. 版权所有