设为首页收藏本站订阅更新

无忧脚本

 找回密码
 加入无忧

QQ登录

只需一步,快速开始

查看: 6222|回复: 39

[推荐] 好久没回51js啦。。。带回来几个原51js的老东西。 [复制链接]

Rank: 2

升级  24.67%

注册时间
2003-2-13
威望
66
阅读权限
20
积分
87
帖子
36
精华
0
UID
262
状态
当前离线
发表于 2007-4-21 12:44:00 |显示全部楼层 |串个门|加好友|打招呼|发消息 |
查看详细资料 查看个人网站
一键分享 一键分享
  1. <html>
  2. <head>
  3. <title>怀念51JS,回家看看。</title>
  4. <meta http-equiv="Content-Type" content="text/html; charset=gb2312">
  5. </head>

  6. <body bgcolor="#FFFFFF" text="#000000" onLoad="blurtext()">
  7. <SCRIPT language=javaScript>
  8. var thissize=11
  9. var textfont="Verdana"

  10. var textcolor= new Array()
  11. textcolor[0]="EEEEEE"
  12. textcolor[1]="DDDDDD"
  13. textcolor[2]="CCCCCC"
  14. textcolor[3]="AAAAAA"
  15. textcolor[4]="888888"
  16. textcolor[5]="666666"
  17. textcolor[6]="555555"
  18. textcolor[7]="444444"
  19. textcolor[8]="333333"
  20. textcolor[9]="222222"
  21. textcolor[10]="111111"
  22. textcolor[11]="000000"

  23. var message = new Array()
  24. message[0]="欢迎访问无忧脚本"
  25. message[1]="我们将把最好的东西共享给你"
  26. message[2]="这个脚本不错吧?"
  27. message[3]="你可以在这里加入不同的东西"
  28. message[4]="比如图片,连接等,都可以的"
  29. message[5]="如果有什么问题的话,直接回帖就可以了"
  30. message[6]="<img src=logo.gif>不要把我们给忘记了"
  31. message[7]="我们会尽力来回答你的问题"
  32. message[8]="我们的网址是 <img src=/moi/file.gif align=absbottom> <a href=\"http://www.51js.com\" target=_blank>http://www.51js.com</a>"
  33. message[9]="如果上网没什么事干的话,可以到我们的聊天区聊聊天南地北的事:)"
  34. message[10]="网络正在渐渐的改变我们的生活"
  35. message[11]="你会使用论坛吗?有很多贴心的功能,找找看"
  36. message[12]="如果在这个版的例子有你喜欢的,记得要放进收藏夹啊!有个收藏夹的图标,点一下就可以了:)"

  37. var i_blurstrength=10
  38. var i_message=0
  39. var i_textcolor=0

  40. function blurtext() {               
  41. if(document.all) {
  42. if (i_blurstrength >=-2) {
  43. if (i_textcolor >=textcolor.length-1) {i_textcolor=textcolor.length-1}
  44. blurthis.innerHTML="<span id='blurpit1' style='position:absolute;visibility:visible;width:600px;top:5px;left:5px;filter:blur(add=0,strength="+i_blurstrength+",direction=90);font-family:"+textfont+";font-size:"+thissize+"pt;color:"+textcolor[i_textcolor]+"'>"+message[i_message]+"</span>";
  45. document.close()
  46. i_blurstrength=i_blurstrength-2
  47. i_textcolor++
  48. var timer=setTimeout("blurtext()",60)
  49. }
  50. else {
  51. if (i_textcolor >=textcolor.length-1) {i_textcolor=textcolor.length-1}
  52. blurthis.innerHTML="<span id='blurit1' style='position:absolute;visibility:visible;width:600px; top:5px;left:5px;filter:blendTrans(duration=4.2);font-family:"+textfont+";font-size:"+thissize+"pt;color:000000'>"+message[i_message]+"</span>";
  53. i_message++
  54. if (i_message>=message.length){i_message=0}
  55. i_blurstrength=20
  56. i_textcolor=0
  57. clearTimeout(timer)
  58. var timer=setTimeout("blurtext()",1000)
  59. }
  60. }       
  61. }
  62. // - End of JavaScript - -->
  63. </SCRIPT>
  64. <DIV id="blurthis" style="position:absolute;visibility:visible;">
  65. </DIV>
  66. </body>
  67. </html>
复制代码运行代码另存代码

Rank: 2

升级  24.67%

注册时间
2003-2-13
威望
66
阅读权限
20
积分
87
帖子
36
精华
0
UID
262
状态
当前离线
发表于 2007-4-21 12:45:55 |显示全部楼层 |串个门|加好友|打招呼|发消息 |
查看详细资料 查看个人网站
  1. <html>
  2. <head>
  3. <title>::你会做,我也要会::</title>
  4. <meta http-equiv="Content-Type" content="text/html; charset=gb2312">
  5. <script language="JavaScript">
  6. <!--
  7. <!--
  8. function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  9.   if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
  10.     document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  11.   else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
  12. }
  13. MM_reloadPage(true);
  14. // -->

  15. function MM_findObj(n, d) { //v4.01
  16.   var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
  17.     d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  18.   if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  19.   for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  20.   if(!x && d.getElementById) x=d.getElementById(n); return x;
  21. }

  22. function P7AniMagic(el, x, y, a, b, c, s) { //v2.5 PVII
  23. var g,elo=el,f="",m=false,d="";x=parseInt(x);y=parseInt(y);
  24. var t = 'g.p7Magic = setTimeout("P7AniMagic(\''+elo+'\',';
  25. if ((g=MM_findObj(el))!=null) {d=(document.layers)?g:g.style;}else{return;}
  26. if (parseInt(s)>0) {eval(t+x+','+y+','+a+','+b+','+c+',0)",' + s+')');return;}
  27. var xx=(parseInt(d.left))?parseInt(d.left):0;
  28. var yy=(parseInt(d.top))?parseInt(d.top):0;
  29. if(parseInt(c)==1) {x+=xx;y+=yy;m=true;c=0;}
  30. else if (c==2) {m=false;clearTimeout(g.p7Magic);}
  31. else {var i=parseInt(a);
  32.   if (eval(g.moved)){clearTimeout(g.p7Magic);}
  33.   if (xx<x){xx+=i;m=true;if(xx>x){xx=x;}}
  34.   if (xx>x){xx-=i;m=true;if(xx<x){xx=x;}}
  35.   if (yy<y){yy+=i;m=true;if(yy>y){yy=y;}}
  36.   if (yy>y){yy-=i;m=true;if(yy<y){yy=y;}}}
  37. if (m) {if((navigator.appName=="Netscape") && parseInt(navigator.appVersion)>4){
  38.     xx+="px";yy+="px";}
  39.   d.left=xx;d.top=yy;g.moved=true;eval(t+x+','+y+','+a+','+b+','+c+',0)",'+b+')');
  40.   }else {g.moved=false;}
  41. }
  42. //-->
  43. </script>
  44. <style type="text/css">
  45. <!--
  46. .t {  filter: Alpha(Opacity=50)}
  47. td {  font-size: 12px; line-height: 22px}
  48. a:link {  color: #FFFFFF; text-decoration: none; height: 20px; width: 63px; border-color: #33CCFF #30CCFF #30CCFF; background-color: #0099FF; border-style: solid; border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px}
  49. a:visited {  color: #FFFFFF; text-decoration: none; height: 20px; width: 63px; border-color: #33CCFF #30CCFF #30CCFF; background-color: #0099FF; border-style: solid; border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px}
  50. a:hover {  background-color: #FF66FF; height: 20px; width: 61px; border: #FFFFFF; border-style: dotted; border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px}
  51. -->
  52. </style>
  53. </head>

  54. <body bgcolor="#FFFFFF" text="#000000">
  55. <div id="Layer1" style="position:absolute; width:200px; height:115px; z-index:1">
  56.   <div id="Layer2" style="position:absolute; left:264px; top:59px; width:67px; height:52px; z-index:2; background-color: #0068FF; layer-background-color: #0068FF; border: 1px none #000000; visibility: visible" class="t">
  57.     <table width="100%" border="0" cellspacing="0" cellpadding="0" height="100%">
  58.       <tr>
  59.         <td align="center" valign="top"><font color="#FFFFFF" onMouseOver="P7AniMagic('Layer2',210,35,5,30,0,0)" onMouseOut="P7AniMagic('Layer2',264,59,5,30,0,0)">on
  60.           1<br>
  61.           <a href="#;">第一项</a><br>
  62.           <a href="#;">第二项</a><br>
  63.           <a href="#;">第三项</a><br>
  64.           </font></td>
  65.       </tr>
  66.     </table>
  67.   </div>
  68.   <div id="Layer3" style="position:absolute; left:264px; top:81px; width:66px; height:84px; z-index:3; background-color: #0066FF; layer-background-color: #0066FF; border: 1px none #000000; visibility: visible" class="t">
  69.     <table width="100%" border="0" cellspacing="0" cellpadding="0">
  70.       <tr>
  71.         <td>
  72.           <div align="center"><font color="#FFFFFF" onMouseOver="P7AniMagic('Layer3',210,55,5,30,0,0)" onMouseOut="P7AniMagic('Layer3',264,81,5,30,0,0)">on 2<br>
  73.             <a href="#;">第一项</a><br>
  74.             <a href="#;">第二项</a><br>
  75.             <a href="#;">第三项</a><br>
  76.             </font></div>
  77.         </td>
  78.       </tr>
  79.     </table>
  80.   </div>
  81.   <div id="Layer4" style="position:absolute; width:68px; height:80px; z-index:4; left: 264px; top: 102px; background-color: #0064FF; layer-background-color: #0064FF; border: 1px none #000000; visibility: visible" class="t">
  82.     <table width="100%" border="0" cellspacing="0" cellpadding="0">
  83.       <tr>
  84.         <td>
  85.           <div align="center"><font color="#FFFFFF" onMouseOver="P7AniMagic('Layer4',210,75,5,30,0,0)" onMouseOut="P7AniMagic('Layer4',264,102,5,30,0,0)">on 3<br>
  86.             <a href="#;">第一项</a><br>
  87.             <a href="#;">第二项</a><br>
  88.             <a href="#;">第三项</a><br>
  89.             </font></div>
  90.         </td>
  91.       </tr>
  92.     </table>
  93.   </div>  <div id="Layer5" style="position:absolute; width:65px; height:127px; z-index:5; left: 265px; top: 56px">
  94.     <table width="100%" border="0" cellspacing="0" cellpadding="0" height="72">
  95.       <tr>
  96.         <td height="24" onMouseOver="P7AniMagic('Layer2',210,35,5,30,0,0)" onMouseOut="P7AniMagic('Layer2',264,59,5,30,0,0)">&nbsp;&nbsp;&nbsp;&nbsp;</td>
  97.       </tr>
  98.       <tr>
  99.         <td height="24" onMouseOver="P7AniMagic('Layer3',210,55,5,30,0,0)" onMouseOut="P7AniMagic('Layer3',264,81,5,30,0,0)">&nbsp;&nbsp;&nbsp;&nbsp;</td>
  100.       </tr>
  101.       <tr>
  102.         <td height="24" onMouseOver="P7AniMagic('Layer4',210,75,5,30,0,0)" onMouseOut="P7AniMagic('Layer4',264,102,5,30,0,0)">&nbsp;&nbsp;&nbsp;&nbsp;</td>
  103.       </tr>
  104.     </table>
  105.   </div>
  106. </div>
  107. </body>
  108. </html>
复制代码运行代码另存代码

使用道具 举报

霸王龙

我是菜菜菜菜菜...鸟

Rank: 6Rank: 6

升级  59.25%

注册时间
2004-10-6
威望
1158
阅读权限
70
积分
2185
帖子
1181
精华
1
UID
17850
状态
当前离线
发表于 2007-4-21 12:46:26 |显示全部楼层 |串个门|加好友|打招呼|发消息 |
查看详细资料
8臭...:loveliness:
这里不是广告位啊,别乱点...!

使用道具 举报

Rank: 2

升级  24.67%

注册时间
2003-2-13
威望
66
阅读权限
20
积分
87
帖子
36
精华
0
UID
262
状态
当前离线
发表于 2007-4-21 12:48:36 |显示全部楼层 |串个门|加好友|打招呼|发消息 |
查看详细资料 查看个人网站
很早以前的,还没有DW的时候,我们就会搞灰度连接了。
  1. <html>
  2. <head>
  3. <title>无标题文档</title>
  4. <meta http-equiv="Content-Type" content="text/html; charset=gb2312">
  5. <style>
  6. <!--
  7. a.xx:link {  filter: Gray; width=1px}
  8. a.xx:visited {  filter: Gray; width=1px}
  9. a.xx:hover {  filter: Chroma(Color=#)}
  10. -->
  11. </style>
  12. </head>

  13. <body bgcolor="#FFFFFF" text="#000000">
  14. <a href="#;" class="xx"><img src="http://bbs.51js.com/images/51js.gif" width="468" height="60" border="0"></a>
  15. </body>
  16. </html>
复制代码运行代码另存代码

使用道具 举报

Rank: 2

升级  24.67%

注册时间
2003-2-13
威望
66
阅读权限
20
积分
87
帖子
36
精华
0
UID
262
状态
当前离线
发表于 2007-4-21 12:50:29 |显示全部楼层 |串个门|加好友|打招呼|发消息 |
查看详细资料 查看个人网站
:L 有人想出了绝对地址

以下是一些很有用的按钮

网上邻居

我的电脑

我的文档

回收站

控制面板

再贴一些绝对地址供大家参考,98、2K、XP下面可能会有不同

拨号网络.{992CFFA0-F557-101A-88EC-00DD010CCC48}
打印机.{2227A280-3AEA-1069-A2DE-08002B30309D}
历史记录.{FF393560-C2A7-11CF-BFF4-444553540000}
回收站.{645FF040-5081-101B-9F08-00AA002F954E}
我的文档.{450D8FBA-AD25-11D0-98A8-0800361B1103}
我的电脑.{20D04FE0-3AEA-1069-A2D8-08002B30309D}
网上邻居.{208D2C60-3AEA-1069-A2D7-08002B30309D}
计划任务.{D6277990-4C6A-11CF-8D87-00AA0060F5BF}

使用道具 举报

Rank: 2

升级  24.67%

注册时间
2003-2-13
威望
66
阅读权限
20
积分
87
帖子
36
精华
0
UID
262
状态
当前离线
发表于 2007-4-21 12:52:21 |显示全部楼层 |串个门|加好友|打招呼|发消息 |
查看详细资料 查看个人网站
马上有人搞出了模糊。。
  1. <html>
  2. <head>
  3. <title>见过没?</title>
  4. <meta http-equiv="Content-Type" content="text/html; charset=gb2312">
  5. <style>
  6. <!--
  7. a.xx:link {  filter: Blur(Add=50, Direction=50, Strength=50); width=1px}
  8. a.xx:visited {  filter: Blur(Add=50, Direction=50, Strength=50); width=1px}
  9. a.xx:hover {  filter: Chroma(Color=#)}
  10. -->
  11. </style>
  12. </head>

  13. <body bgcolor="#FFFFFF" text="#000000">
  14. <a href="#;" class="xx"><img src="http://bbs.51js.com/images/51js.gif" width="468" height="60" border="0"></a>
  15. </body>
  16. </html>
复制代码运行代码另存代码

使用道具 举报

Rank: 2

升级  24.67%

注册时间
2003-2-13
威望
66
阅读权限
20
积分
87
帖子
36
精华
0
UID
262
状态
当前离线
发表于 2007-4-21 12:53:46 |显示全部楼层 |串个门|加好友|打招呼|发消息 |
查看详细资料 查看个人网站
巨大滴广告。。我们也是第一时间会的。

  1. <html>
  2. <head>
  3. <title>广告演示</title>
  4. <meta http-equiv="Content-Type" content="text/html; charset=gb2312">
  5. </head>
  6. <script>
  7. function moveLayer(){
  8.         if(advLayer.style.pixelTop>-parseInt(advLayer.clientHeight)) {
  9.                 advLayer.style.pixelTop-=2;
  10.                 setTimeout("moveLayer()",1);
  11.                 } else {advLayer.style.display="none"}
  12. }

  13. function advout(){
  14.         setTimeout("moveLayer()",1000);//一秒种后开始移动
  15. }

  16. </script>

  17. <body bgcolor="#FFFFFF" text="#000000" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" onload="advout()">
  18. <div id="advLayer" style="position:absolute; left:0; top:0; width:100%; height:100%; z-index:1; background-color: #999900; layer-background-color: #999900; border: 1px none #000000">
  19. <!--
  20. 这里插入广告内容
  21. -->
  22.   <div align="center"><img src="Winxp1.jpg" width="600" height="450"></div>
  23. </div>

  24. <table width="100%" border="0" cellspacing="2" cellpadding="1" height="100%">
  25.   <tr>
  26.     <td>
  27.       <table width="500" border="0" cellspacing="2" cellpadding="2" align="center">
  28.         <tr>
  29.           <td bgcolor="#999900"> </td>
  30.         </tr>
  31.         <tr>
  32.           <td bgcolor="#003399" height="143">
  33.             <div align="center"><font color="#FFFFFF"><b>页面</b></font> </div>
  34.           </td>
  35.         </tr>
  36.         <tr>
  37.           <td bgcolor="#FF9900"> </td>
  38.         </tr>
  39.       </table>
  40.     </td>
  41.   </tr>
  42. </table>
  43. </body>
  44. </html>
复制代码运行代码另存代码

使用道具 举报

Rank: 2

升级  24.67%

注册时间
2003-2-13
威望
66
阅读权限
20
积分
87
帖子
36
精华
0
UID
262
状态
当前离线
发表于 2007-4-21 12:54:55 |显示全部楼层 |串个门|加好友|打招呼|发消息 |
查看详细资料 查看个人网站
小东西我们也搞。。搞到这种有七没八的东西都出来了

滚动条跑左边去了

  1. <body dir=rtl><p align=left>hehe</p>
复制代码运行代码另存代码

使用道具 举报

Rank: 2

升级  24.67%

注册时间
2003-2-13
威望
66
阅读权限
20
积分
87
帖子
36
精华
0
UID
262
状态
当前离线
发表于 2007-4-21 12:55:58 |显示全部楼层 |串个门|加好友|打招呼|发消息 |
查看详细资料 查看个人网站
我们整天搞这个搞那个。
  1. <html>
  2. <head>
  3. <title>渐隐渐现文本公告板</title>
  4. <meta http-equiv="Content-Type" content="text/html; charset=gb2312">
  5. </head>

  6. <body bgcolor="#FFFFFF" text="#000000">
  7. <script language="JavaScript1.2">



  8. var delay=3000 //set delay between message change (in miliseconds)
  9. var fcontent=new Array()
  10. begintag='<font face="Arial" size=2>' //set opening tag, such as font declarations
  11. fcontent[0]="<b>Scriptkit.com</b><br><br>欢迎您光临,感谢您提出宝贵意见<br><br>有意见和问题请在论坛中提出"
  12. fcontent[1]="<b>Scriptkit.com</b><br><br>  特效代码为网站设计师和网页爱好者提供专业的特效代码"
  13. fcontent[2]="<b>Scriptkit.com</b><br><br>  相关下载栏目提供全面的Dreamweaver插件下载,让您的DW功能更强大!"
  14. closetag='</font>'

  15. var fwidth=150 //set scroller width
  16. var fheight=150 //set scroller height

  17. ///No need to edit below this line/////////////////

  18. var ie4=document.all&&!document.getElementById
  19. var ns4=document.layers
  20. var DOM2=document.getElementById
  21. var faderdelay=0
  22. var index=0

  23. if (DOM2)
  24. faderdelay=2000

  25. //function to change content
  26. function changecontent(){
  27. if (index>=fcontent.length)
  28. index=0
  29. if (DOM2){
  30. document.getElementById("fscroller").style.color="rgb(255,255,255)"
  31. document.getElementById("fscroller").innerHTML=begintag+fcontent[index]+closetag
  32. colorfade()
  33. }
  34. else if (ie4)
  35. document.all.fscroller.innerHTML=begintag+fcontent[index]+closetag
  36. else if (ns4){
  37. document.fscrollerns.document.fscrollerns_sub.document.write(begintag+fcontent[index]+closetag)
  38. document.fscrollerns.document.fscrollerns_sub.document.close()
  39. }

  40. index++
  41. setTimeout("changecontent()",delay+faderdelay)
  42. }

  43. // colorfade() partially by Marcio Galli for Netscape Communications.  ////////////
  44. // Modified by Dynamicdrive.com

  45. frame=20;
  46. hex=255  // Initial color value.

  47. function colorfade() {                        
  48. // 20 frames fading process
  49. if(frame>0) {       
  50. hex-=12; // increase color value
  51. document.getElementById("fscroller").style.color="rgb("+hex+","+hex+","+hex+")"; // Set color value.
  52. frame--;
  53. setTimeout("colorfade()",20);       
  54. }
  55. else{
  56. document.getElementById("fscroller").style.color="rgb(0,0,0)";
  57. frame=20;
  58. hex=255
  59. }   
  60. }

  61. if (ie4||DOM2)
  62. document.write('<div id="fscroller" style="border:1px solid black;width:'+fwidth+';height:'+fheight+';padding:2px"></div>')

  63. window.onload=changecontent
  64. </script>

  65. <ilayer id="fscrollerns" width=&{fwidth}; height=&{fheight};><layer id="fscrollerns_sub" width=&{fwidth}; height=&{fheight}; left=0 top=0></layer></ilayer>

  66. </body>
  67. </html>
复制代码运行代码另存代码

使用道具 举报

Rank: 2

升级  24.67%

注册时间
2003-2-13
威望
66
阅读权限
20
积分
87
帖子
36
精华
0
UID
262
状态
当前离线
发表于 2007-4-21 12:57:39 |显示全部楼层 |串个门|加好友|打招呼|发消息 |
查看详细资料 查看个人网站
一天到晚做些没用的小玩意。。。
  1. <script>
  2. function oMove()
  3. {
  4.   var x=event.x;
  5.   var y=event.y;
  6.   if (y>0&&y<300)
  7.   {obj.style.top =y;}
  8.   if (x>200&&x<500)
  9.   {obj1.style.left =x; }
  10. }
  11. </script>
  12. <body onmousemove="oMove()">
  13. <div id="obj" style="position:absolute;left:200;top:200">移动的字!</div>
  14. <div id="obj1" style="position:absolute;left:200;top:0">移动的字!</div>
复制代码运行代码另存代码

使用道具 举报

Rank: 2

升级  24.67%

注册时间
2003-2-13
威望
66
阅读权限
20
积分
87
帖子
36
精华
0
UID
262
状态
当前离线
发表于 2007-4-21 13:01:53 |显示全部楼层 |串个门|加好友|打招呼|发消息 |
查看详细资料 查看个人网站
做好事从不留名。。。。以下这段谁写的我都记不得了。
  1. <SCRIPT language=JavaScript1.2>
  2. var scrollerwidth=200
  3. var scrollerheight=133
  4. var scrollerbgcolor='white'
  5. //3000 miliseconds=3 seconds
  6. var pausebetweenimages=3000
  7. var slideimages=new Array()
  8. slideimages[0]='<img src="http://bbs.51js.com/images/51js.gif">'
  9. slideimages[1]='<img src="http://bbs.51js.com/images/default/logo.gif">'
  10. slideimages[2]='<img src="http://bbs.51js.com/images/default/newtopic.gif">'
  11. slideimages[3]='<img src="http://bbs.51js.com/images/default/logo.gif">'
  12. slideimages[4]='<img src="http://bbs.51js.com/images/default/reply.gif">'
  13. slideimages[5]='<img src="052.gif">'
  14. slideimages[6]='<img src="074.gif">'
  15. slideimages[7]='<img src="053.gif">'
  16. slideimages[8]='<img src="054.gif">'
  17. slideimages[9]='<img src="055.gif">'
  18. slideimages[10]='<img src="056.gif">'
  19. slideimages[11]='<img src="073.gif">'

  20. //extend this list

  21. ///////Do not edit pass this line///////////////////////
  22.      

  23. if (slideimages.length>1)
  24. i=2
  25. else
  26. i=0

  27. function move1(whichlayer){
  28. tlayer=eval(whichlayer)
  29. if (tlayer.top>0&&tlayer.top<=5){
  30. tlayer.top=0
  31. setTimeout("move1(tlayer)",pausebetweenimages)
  32. setTimeout("move2(document.main.document.second)",pausebetweenimages)
  33. return
  34. }
  35. if (tlayer.top>=tlayer.document.height*-1){
  36. tlayer.top-=5
  37. setTimeout("move1(tlayer)",100)
  38. }
  39. else{
  40. tlayer.top=scrollerheight
  41. tlayer.document.write(slideimages[i])
  42. tlayer.document.close()
  43. if (i==slideimages.length-1)
  44. i=0
  45. else
  46. i++
  47. }
  48. }

  49. function move2(whichlayer){
  50. tlayer2=eval(whichlayer)
  51. if (tlayer2.top>0&&tlayer2.top<=5){
  52. tlayer2.top=0
  53. setTimeout("move2(tlayer2)",pausebetweenimages)
  54. setTimeout("move1(document.main.document.first)",pausebetweenimages)
  55. return
  56. }
  57. if (tlayer2.top>=tlayer2.document.height*-1){
  58. tlayer2.top-=5
  59. setTimeout("move2(tlayer2)",100)
  60. }
  61. else{
  62. tlayer2.top=scrollerheight
  63. tlayer2.document.write(slideimages[i])
  64. tlayer2.document.close()
  65. if (i==slideimages.length-1)
  66. i=0
  67. else
  68. i++
  69. }
  70. }

  71. function move3(whichdiv){
  72. tdiv=eval(whichdiv)
  73. if (tdiv.style.pixelTop>0&&tdiv.style.pixelTop<=5){
  74. tdiv.style.pixelTop=0
  75. setTimeout("move3(tdiv)",pausebetweenimages)
  76. setTimeout("move4(second2)",pausebetweenimages)
  77. return
  78. }
  79. if (tdiv.style.pixelTop>=tdiv.offsetHeight*-1){
  80. tdiv.style.pixelTop-=5
  81. setTimeout("move3(tdiv)",100)
  82. }
  83. else{
  84. tdiv.style.pixelTop=scrollerheight
  85. tdiv.innerHTML=slideimages[i]
  86. if (i==slideimages.length-1)
  87. i=0
  88. else
  89. i++
  90. }
  91. }

  92. function move4(whichdiv){
  93. tdiv2=eval(whichdiv)
  94. if (tdiv2.style.pixelTop>0&&tdiv2.style.pixelTop<=5){
  95. tdiv2.style.pixelTop=0
  96. setTimeout("move4(tdiv2)",pausebetweenimages)
  97. setTimeout("move3(first2)",pausebetweenimages)
  98. return
  99. }
  100. if (tdiv2.style.pixelTop>=tdiv2.offsetHeight*-1){
  101. tdiv2.style.pixelTop-=5
  102. setTimeout("move4(second2)",100)
  103. }
  104. else{
  105. tdiv2.style.pixelTop=scrollerheight
  106. tdiv2.innerHTML=slideimages[i]
  107. if (i==slideimages.length-1)
  108. i=0
  109. else
  110. i++
  111. }
  112. }

  113. function startscroll(){
  114. if (document.all){
  115. move3(first2)
  116. second2.style.top=scrollerheight
  117. }
  118. else if (document.layers){
  119. document.main.visibility='show'
  120. move1(document.main.document.first)
  121. document.main.document.second.top=scrollerheight+5
  122. document.main.document.second.visibility='show'
  123. }
  124. }

  125. window.onload=startscroll

  126. </SCRIPT>
  127. <SCRIPT language=JavaScript1.2>
  128. if (document.all){
  129. document.writeln('<center><span id="main2" style="position:relative;width:'+scrollerwidth+';height:'+scrollerheight+';overflow:hiden;background-color:'+scrollerbgcolor+'">')
  130. document.writeln('<div style="position:absolute;width:'+scrollerwidth+';height:'+scrollerheight+';clip:rect(0 '+scrollerwidth+' '+scrollerheight+' 0);left:0;top:0">')
  131. document.writeln('<div id="first2" style="position:absolute;width:'+scrollerwidth+';left:0;top:1;">')
  132. document.write(slideimages[0])
  133. document.writeln('</div>')
  134. document.writeln('<div id="second2" style="position:absolute;width:'+scrollerwidth+';left:0;top:0">')
  135. document.write(slideimages[1])
  136. document.writeln('</div>')
  137. document.writeln('</div>')
  138. document.writeln('</span>')
  139. }
  140. </SCRIPT>
复制代码运行代码另存代码

使用道具 举报

Rank: 2

升级  24.67%

注册时间
2003-2-13
威望
66
阅读权限
20
积分
87
帖子
36
精华
0
UID
262
状态
当前离线
发表于 2007-4-21 13:04:16 |显示全部楼层 |串个门|加好友|打招呼|发消息 |
查看详细资料 查看个人网站
  1. <html>
  2. <head>
  3. <meta http-equiv="Content-Language" content="zh-cn">
  4. <meta http-equiv="Content-Type" content="text/html; charset=gb2312">
  5. <meta name="GENERATOR" content="Microsoft FrontPage 4.0">
  6. <meta name="ProgId" content="FrontPage.Editor.Document">
  7. <title>用户ID</title>
  8. <style>
  9. <!--
  10. td           { font-size: 9pt }
  11. -->
  12. </style>
  13. <script language="javascript">
  14. <!--
  15. var row_index=0;
  16. //建立一个函数build_row()用于建立新的一行且增加的四个文本框为空的且被禁用
  17. function build_row(){
  18.         row_index++;
  19.         var new_row=Table1.insertRow(Table1.rows.length);
  20.         new_row.setAttribute("id", "row"+row_index);
  21.         var new_col=new_row.insertCell(0);
  22.         new_col.innerHTML="<input type='text' name='T1"+row_index+"' size='20' disabled>";
  23.         var new_col=new_row.insertCell(1);
  24.         new_col.innerHTML="<input type='text' name='T2"+row_index+"' size='20' disabled>";
  25.         var new_col=new_row.insertCell(2);
  26.         new_col.innerHTML="<input type='text' name='T3"+row_index+"' size='8' disabled>";
  27.         var new_col=new_row.insertCell(3);
  28.         new_col.innerHTML="<input type='text' name='T4"+row_index+"' size='8' disabled>";
  29.         var new_col=new_row.insertCell(4);
  30.         new_col.innerHTML="<input type='button' value='添加' name='B5"+row_index+"' LANGUAGE='javascript' onclick='add_data("+row_index+")'>";
  31.         var new_col=new_row.insertCell(5);
  32.         new_col.innerHTML="<input type='button' value='删除此行' name='B4"+row_index+"' LANGUAGE='javascript' onclick=\"delete_row('row"+row_index+ "')\">";
  33.     }
  34. //建立一个函数age_average()用于计算年龄的平均值
  35. function age_average()
  36. {
  37.         var i,j,temp,age_sum=0;var j=0;
  38.         for (i=1;i<=Table1.rows.length-1;i++)
  39.         {
  40.         temp=eval("form1.T4"+Table1.rows(i).id.substr(3));
  41.                 if (temp.value==""){
  42.                
  43.                 j++;
  44.                 age_sum=age_sum;
  45.                 }
  46.                 else{
  47.                 age_sum+=parseInt(temp.value);
  48.                 }
  49.                
  50.         }
  51.         form1.T5.value=(age_sum/(Table1.rows.length-1-j));
  52. }
  53. //建立一个函数add_data()用于添加数据
  54. function add_data(rname){
  55. var i;
  56. form1.hidden_index.value=Table1.rows(rname).rowIndex;
  57. var win_new=open("list.htm")
  58.         }

  59. //建立一个函数delete_row用于删除一行
  60. function delete_row(rname)
  61. {
  62.         var i;
  63.         i=Table1.rows(rname).rowIndex;
  64.         alert(i);
  65.         Table1.deleteRow(i);
  66.         }
  67. //建立一个函数check_form()用于检查文本框是否为空
  68. function check_form(){
  69.          var i;
  70.                  for(i=1;i<=Table1.rows.length-1;i++){
  71.                         if (eval("form1.T1"+Table1.rows(i).id.substr(3)).value=="" || eval("form1.T2"+Table1.rows(i).id.substr(3)).value=="" || eval("form1.T3"+Table1.rows(i).id.substr(3)).value=="" || eval("form1.T4"+Table1.rows(i).id.substr(3)).value==""){
  72.                         alert("请检察是否有文本框为空");
  73.                         return false;
  74.                 }
  75.         }
  76. }                  

  77. //-->
  78. </script>
  79. </head>  
  80. <body>
  81. <form id=form1 method="POST" action="submit.htm" language="javascript" onsubmit="return check_form()" >
  82. <input type="hidden" name="hidden_index" value="">
  83. <table border="1" width="58%" bordercolor="#000000" cellspacing="0" cellpadding="0" bordercolordark="#FFFFFF" height="16" id=Table1>
  84.   <tr>
  85.     <td width="15%" align="center" bgcolor="#E6E6E6" height="16">用户ID </td>
  86.     <td width="24%" align="center" bgcolor="#E6E6E6" height="16">用户名</td>
  87.     <td width="7%" align="center" bgcolor="#E6E6E6" height="16">性别</td>
  88.     <td width="8%" align="center" bgcolor="#E6E6E6" height="16">年龄</td>
  89.     <td width="34%" align="center" bgcolor="#E6E6E6" height="16">添加</td>
  90.     <td width="21%" align="center" bgcolor="#E6E6E6" height="16">删除</td>
  91.   </tr>   
  92. </table>
  93.   <p><input type="button" value="增加一行" name="B3"  onclick="build_row()"><input type="submit" value="提交" name="B1"><input type="button" value="平均年龄" name="B6" onClick="age_average()"><input type="text" name="T5" size="7">岁</p>
  94. </form>

  95. <table border="1" width="100%" bordercolor="#000000" cellspacing="0" cellpadding="0" bordercolordark="#FFFFFF" height="54">
  96.   <tr>
  97.     <td width="100%" bgcolor="#E6E6E6" height="27">
  98.       <p align="center">设计要求</td>
  99.   </tr>
  100.   <tr>
  101.     <td width="100%" height="93">1.当用户点击"增加一行",Table就增加一个Tr(包括四个文本框,"添加","删除此行"两个按钮。)。<br>
  102.       2.增加的四个文本框为空的且被禁用,用户只要点击"添加"按钮来选择用户的值。<br>
  103.       3.当用户点击"添加"按钮,就弹出新窗口,新窗口为一用户列表,用户列表只有"用户ID"和"用户名"两个字段显示.<br>
  104.       4.当选择用户列表Onmouseover时,鼠标变成"hand",当前行的TR的bgcolor为蓝色,字为白色。当用户onclick时,相应的值就添加到四个文本框中。新窗口自动关闭。<br>
  105.       5.当用户点击"删除此行"按钮时,整个相应的Tr就被删除。<br>
  106.       6.算出"平均年龄"<br>
  107.       7.在提交前,要判断是否有文本框为空,用空的就不能提交,提示用户进行添加。</td>
  108.   </tr>
  109.   <tr>
  110.     <td width="100%" height="23" bgcolor="#E6E6E6">难度:较难?????????
  111.       完成时间:半天</td>
  112.   </tr>
  113. </table>

  114. </body>

  115. </html>
复制代码运行代码另存代码

有人想就有人做。。我们就是51js人

使用道具 举报

Rank: 2

升级  24.67%

注册时间
2003-2-13
威望
66
阅读权限
20
积分
87
帖子
36
精华
0
UID
262
状态
当前离线
发表于 2007-4-21 13:07:11 |显示全部楼层 |串个门|加好友|打招呼|发消息 |
查看详细资料 查看个人网站
:lol :lol 看看某人小时候的作品。。 嘻嘻 嘻。。。。。。
  1. 菜单很好。
  2. <!-- 本页由flashsoft2000完成 -->
  3. <meta http-equiv="Content-Type" content="text/html; charset=gb2312">
  4. <style>
  5. body,td,a {font-size:9pt;color:black;text-decoration:none}
  6. .normal {padding:2px}
  7. .up {padding:1px;border:#999999 1px solid;background:#cccccc}
  8. .down {padding:1px;border:dbdbdb 1px solid;background:dbdbdb}
  9. .menuv {filter: revealTrans(transition=23,duration=0.5);position: absolute; visibility: hidden; padding:2px}
  10. </style>
  11. <body onmousemove="move()">
  12. <script>
  13. //闪烁的表格边框
  14. function flashit(){if(!document.all)return;if (td123.style.borderColor=="black")td123.style.borderColor="#999999";else td123.style.borderColor="black"}setInterval("flashit()",500)
  15. //渐入的效果,改变alpha值
  16. function high(image){theobject=image,highlighting=setInterval("highlightit(theobject)",100)}function low(image){clearInterval(highlighting),image.filters.alpha.opacity=50}function highlightit(cur2){if (cur2.filters.alpha.opacity<100)cur2.filters.alpha.opacity+=20;else if(window.highlighting)clearInterval (highlighting)}
  17. //拖动层的js
  18. var over=false,down=false,divleft,divtop;function move(){if(down){plane.style.left=event.clientX-divleft;plane.style.top=event.clientY-divtop;}}
  19. </script>
  20. <script language="javaScript">
  21. <!--
  22. function Show(divid) {
  23. divid.filters.revealTrans.apply();
  24. divid.style.visibility = "visible";
  25. divid.filters.revealTrans.play();
  26. }
  27. function Hide(divid) {
  28. divid.filters.revealTrans.apply();
  29. divid.style.visibility = "hidden";
  30. divid.filters.revealTrans.play();
  31. }
  32. //-->
  33. </script>
  34. <div style="position:absolute;z-index:1;width:1;height:1; left: 100; top: 100" ID=plane onmousedown="down=true;divleft=event.clientX-parseInt(plane.style.left);divtop=event.clientY-parseInt(plane.style.top)" onmouseup="down=false">
  35. <table id="td123" cellspacing=2 width=100 border=0 style="BORDER:#999999 1px solid;cursor:hand" cellpadding="0" bgcolor="f4f4f4">
  36. <tr>
  37. <td bgcolor="#cccccc" height="20" style="BORDER:#999999 1px solid;cursor:move">
  38. <div align="center">无聊的菜单</div>
  39. </td>
  40. </tr>
  41. <tr>
  42. <td class=normal onMouseDown="this.className='down'"
  43. onMouseOver="this.className='up',high(this),Show(menu1)
  44. " onMouseOut="this.className='normal',low(this),menu1.style.visibility='hidden'" style="filter:alpha(opacity=50)"onMouseUp="this.className='up'" >
  45. <div align="right">有下级菜单&gt;&gt;</div>
  46. </td>
  47. </tr>
  48. <tr>
  49. <td class=normal onMouseDown="this.className='down'"
  50. onMouseOver="this.className='up',high(this),Show(menu2)" onMouseOut="this.className='normal',low(this),menu2.style.visibility='hidden'" style="filter:alpha(opacity=50)"onMouseUp="this.className='up'" >
  51. <div align="right">有下级菜单&gt;&gt;</div>
  52. </td>
  53. </tr>
  54. <tr>
  55. <td class=normal onMouseDown="this.className='down'"
  56. onMouseOver="this.className='up',high(this)" onMouseOut="this.className='normal',low(this)" style="filter:alpha(opacity=50)"onMouseUp="this.className='up'">
  57. <div align="right">无下级菜单&gt;&gt;</div>
  58. </td>
  59. </tr>
  60. <tr>
  61. <td class=normal onMouseDown="this.className='down'"
  62. onMouseOver="this.className='up',high(this)" onMouseOut="this.className='normal',low(this)" style="filter:alpha(opacity=50)"onMouseUp="this.className='up'">
  63. <div align="right">无下级菜单&gt;&gt;</div>
  64. </td>
  65. </tr>
  66. </table>
  67. <div id="menu1" style="position:absolute;top:24px;left:96px; z-index:1; visibility: hidden; width: 105"
  68. onMouseOver=this.style.visibility='visible'
  69. onMouseOut=this.style.visibility='hidden' class="menuv">
  70. <table cellspacing=2 width=100 border=0 style="BORDER:#999999 1px solid;cursor:hand" cellpadding="0" bgcolor="f4f4f4" align="right">
  71. <tr>
  72. <td class=normal onMouseDown="this.className='down'"
  73. onMouseOver="this.className='up',high(this)" onMouseOut="this.className='normal',low(this)" style="filter:alpha(opacity=50)"onMouseUp="this.className='up'">
  74. <div align="center">子菜单</div>
  75. </td>
  76. </tr>
  77. <tr>
  78. <td class=normal onMouseDown="this.className='down'"
  79. onMouseOver="this.className='up',high(this)" onMouseOut="this.className='normal',low(this)" style="filter:alpha(opacity=50)"onMouseUp="this.className='up'">
  80. <div align=center>子菜单</div>
  81. </td>
  82. </tr>
  83. <tr>
  84. <td class=normal onMouseDown="this.className='down'"
  85. onMouseOver="this.className='up',high(this)" onMouseOut="this.className='normal',low(this)" style="filter:alpha(opacity=50)"onMouseUp="this.className='up'">
  86. <div align=center>子菜单</div>
  87. </td>
  88. </tr>
  89. <tr>
  90. <td class=normal onMouseDown="this.className='down'"
  91. onMouseOver="this.className='up',high(this)" onMouseOut="this.className='normal',low(this)" style="filter:alpha(opacity=50)"onMouseUp="this.className='up'">
  92. <div align=center>子菜单</div>
  93. </td>
  94. </tr>
  95. </table>
  96. </div>
  97. <div id="menu2" style="position:absolute;top:45px;left:96; z-index:1; visibility: hidden; width: 105"
  98. onMouseOver=this.style.visibility='visible'
  99. onMouseOut=this.style.visibility='hidden' class="menuv">
  100. <table cellspacing=2 width=100 border=0 style="BORDER:#999999 1px solid;cursor:hand" cellpadding="0" bgcolor="f4f4f4" align="right">
  101. <tr>
  102. <td class=normal onMouseDown="this.className='down'"
  103. onMouseOver="this.className='up',high(this)" onMouseOut="this.className='normal',low(this)" style="filter:alpha(opacity=50)"onMouseUp="this.className='up'">
  104. <div align="center">子菜单</div>
  105. </td>
  106. </tr>
  107. <tr>
  108. <td class=normal onMouseDown="this.className='down'"
  109. onMouseOver="this.className='up',high(this)" onMouseOut="this.className='normal',low(this)" style="filter:alpha(opacity=50)"onMouseUp="this.className='up'">
  110. <div align=center>子菜单</div>
  111. </td>
  112. </tr>
  113. <tr>
  114. <td class=normal onMouseDown="this.className='down'"
  115. onMouseOver="this.className='up',high(this)" onMouseOut="this.className='normal',low(this)" style="filter:alpha(opacity=50)"onMouseUp="this.className='up'">
  116. <div align=center>子菜单</div>
  117. </td>
  118. </tr>
  119. <tr>
  120. <td class=normal onMouseDown="this.className='down'"
  121. onMouseOver="this.className='up',high(this)" onMouseOut="this.className='normal',low(this)" style="filter:alpha(opacity=50)"onMouseUp="this.className='up'">
  122. <div align=center>子菜单</div>
  123. </td>
  124. </tr>
  125. </table>
  126. </div>
  127. </div>
复制代码运行代码另存代码

使用道具 举报

Rank: 2

升级  24.67%

注册时间
2003-2-13
威望
66
阅读权限
20
积分
87
帖子
36
精华
0
UID
262
状态
当前离线
发表于 2007-4-21 13:09:05 |显示全部楼层 |串个门|加好友|打招呼|发消息 |
查看详细资料 查看个人网站
:lol :lol

有没有老不死的记得我哟。。。。

使用道具 举报

Rank: 2

升级  24.67%

注册时间
2003-2-13
威望
66
阅读权限
20
积分
87
帖子
36
精华
0
UID
262
状态
当前离线
发表于 2007-4-21 13:14:50 |显示全部楼层 |串个门|加好友|打招呼|发消息 |
查看详细资料 查看个人网站
或许现在很多人有先进的工具软件。。这些已经不再是难事。

但是,你可以从这些旧东西里,发现51JS人的创造精神。

:lol :lol :lol

可爱的创新。。JS 需要的不是按步就搬,而是创新。

使用道具 举报

Rank: 2

升级  16.67%

注册时间
2007-4-20
威望
33
阅读权限
20
积分
75
帖子
33
精华
0
UID
68562
状态
当前离线
发表于 2007-4-21 14:09:26 |显示全部楼层 |串个门|加好友|打招呼|发消息 |
查看详细资料
不错
是个高手,斑竹您能帮我解决下我的问题吗?

我用的jsp+servlert 在文本框里输入的内容到达最右侧以后,文本内容就会自动回行
而我在存入数据库显示的时候想要得到和录入的形式完全符合的内容,没有办法获得。
即我只能找到硬回车而无法识别内容满以后自动回行的内容。
我现在想有没有一种方法可以从文本域中获得一行一行的读取内容,类似于读文本文件的readline
哪位高手能帮我下,给点建议

使用道具 举报

超级版主

振兴无忧

Rank: 8Rank: 8

注册时间
2004-5-6
威望
1334
阅读权限
150
积分
2410
帖子
1368
精华
9
UID
11191
状态
当前离线
发表于 2007-4-21 14:14:03 |显示全部楼层 |串个门|加好友|打招呼|发消息 |
查看详细资料
在效果充拆的年代,真是怀念了。我记得那时我最喜欢写的也就是js的鼠标跟随了:)

那是2003年,我大二,刚从学校的西区搬到东区。在网吧里留下很多我写js代码的例子,继而幼稚,继而疯狂

[ 本帖最后由 逍遥云 于 2007-4-21 14:16 编辑 ]

使用道具 举报

Rank: 2

升级  16.67%

注册时间
2007-4-20
威望
33
阅读权限
20
积分
75
帖子
33
精华
0
UID
68562
状态
当前离线
发表于 2007-4-21 14:16:11 |显示全部楼层 |串个门|加好友|打招呼|发消息 |
查看详细资料
大家有谁解决过这个问题吗 帮帮小弟 谢谢了

使用道具 举报

Rank: 3Rank: 3

升级  18%

注册时间
2007-3-27
威望
140
阅读权限
30
积分
254
帖子
133
精华
0
UID
67035
状态
当前离线
发表于 2007-4-21 14:19:38 |显示全部楼层 |串个门|加好友|打招呼|发消息 |
查看详细资料
JS 需要的不是按步就搬,而是创新。

使用道具 举报

Rank: 2

升级  16.67%

注册时间
2007-4-20
威望
33
阅读权限
20
积分
75
帖子
33
精华
0
UID
68562
状态
当前离线
发表于 2007-4-21 14:25:12 |显示全部楼层 |串个门|加好友|打招呼|发消息 |
查看详细资料
我已经苦恼好多天了 我也想创新啊 没法实现啊

使用道具 举报

您需要登录后才可以回帖 登录 | 加入无忧

Archiver|手机版|无忧脚本 ( 苏ICP备05080427号 )|值班电话:027-62300445  

GMT+8, 2012-2-7 21:44 , Processed in 0.067978 second(s), 14 queries , Gzip On, Memcache On.

Powered by Discuz! X2

© 1999-2011 无忧脚本

回顶部