非常奇怪的问题
把下面的代码存为.htm直接打开运行正常
当用http://localhost/XXX.htm运行也正常
但传到网上或在本地用ip访问却不正常
<script> var Groupcount2;Groupcount2=0;var Group2 = new Array();var refurbishtime2 = 10*1000; var theTimer2; var counts2=0;document.write( " <table width=914 border=0 cellpadding=0 cellspacing=0> <tr> <td height=10> </td> </tr> <tr> <td valign=top> <table width=100% border=0 cellspacing=0 cellpadding=0> <tr align=center> <td width=12% valign=top> <div class=addimg> <a href=# id= 'newhref0 ' target=_blank> <img id= 'newimgInit0 ' style= 'FILTER: revealTrans(duration=1,transition=23); ' src=# width=75 height=75 border=0> </a> </A> </DIV> <a class=textorg href=# id= 'newBloghref0 ' target=_blank class= 'id '> <div id= 'newBlogdiv0 ',style= 'border:0px; '> A </div> </a> </td> <td width=12% valign=top> <div class=addimg> <a href=# id= 'newhref1 ' target=_blank> <img id= 'newimgInit1 ' style= 'FILTER: revealTrans(duration=1,transition=23); ' src=# width=75 height=75 border=0> </a> </A> </DIV> <a class=textorg href=# id= 'newBloghref1 ' target=_blank class= 'id '> <div id= 'newBlogdiv1 ',style= 'border:0px; '> B </div> </a> </td> <td width=12% valign=top> <div class=addimg> <a href=# id= 'newhref2 ' target=_blank> <img id= 'newimgInit2 ' style= 'FILTER: revealTrans(duration=1,transition=23); ' src=# width=75 height=75 border=0> </a> </A> </DIV> <a class=textorg href=# id= 'newBloghref2 ' target=_blank class= 'id '> <div id= 'newBlogdiv2 ',style= 'border:0px; '> C </div> </a> </td> <td width=12% valign=top> <div class=addimg> <a href=# id= 'newhref3 ' target=_blank> <img id= 'newimgInit3 ' style= 'FILTER: revealTrans(duration=1,transition=23); ' src=# width=75 height=75 border=0> </a> </A> </DIV> <a class=textorg href=# id= 'newBloghref3 ' target=_blank class= 'id '> <div id= 'newBlogdiv3 ',style= 'border:0px; '> C </div> </a> </td> <td width=12% valign=top> <div class=addimg> <a href=# id= 'newhref4 ' target=_blank> <img id= 'newimgInit4 ' style= 'FILTER: revealTrans(duration=1,transition=23); ' src=# height=75 border=0> </a> </A> </DIV> <a class=textorg href=# id= 'newBloghref4 ' target=_blank class= 'id '> <div id= 'newBlogdiv4 ',style= 'border:0px; '> E </div> </a> </td> <td width=12% valign=top> <div class=addimg> <a href=# id= 'newhref5 ' target=_blank> <img id= 'newimgInit5 ' style= 'FILTER: revealTrans(duration=1,transition=23); ' src=# width=75 height=75 border=0> </a> </A> </DIV> <a class=textorg href=# id= 'newBloghref5 ' target=_blank class= 'id '> <div id= 'newBlogdiv5 ',style= 'border:0px; '> F </div> </a> </td> <td width=12% valign=top> <div class=addimg> <a href=# id= 'newhref6 ' target=_blank> <img id= 'newimgInit6 ' style= 'FILTER: revealTrans(duration=1,transition=23); ' src=# width=75 height=75 border=0> </a> </A> </DIV> <a class=textorg href=# id= 'newBloghref6 ' target=_blank class= 'id '> <div id= 'newBlogdiv6 ',style= 'border:0px; '> G </div> </a> </td> <td width=12% valign=top> <div class=addimg> <a href=# id= 'newhref7 ' target=_blank> <img id= 'newimgInit7 ' style= 'FILTER: revealTrans(duration=1,transition=23); ' src=# width=75 height=75 border=0> </a> </A> </DIV> <a class=textorg href=# id= 'newBloghref7 ' target=_blank class= 'id '> <div id= 'newBlogdiv7 ',style= 'border:0px; '> H </div> </a> </td> </tr> </table> </td> </tr> </table> ")
Group2[Groupcount2++] = new Array( '../h/2007/8/11/584.aspx ', '天时嘉园 ', '/shangpinf/Attachment/6408.jpg ', '10973181 ', '6408.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/8/11/583.aspx ', '盛北家苑 ', '/shangpinf/Attachment/6393.jpg ', '10973181 ', '6393.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/8/11/582.aspx ', '御金名苑 ', '/shangpinf/Attachment/6368.jpg ', '10973181 ', '6368.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/8/11/581.aspx ', '水木康桥 ', '/shangpinf/Attachment/6407.jpg ', '10973181 ', '6407.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/8/11/580.aspx ', '新湖峰尚 ', '/shangpinf/Attachment/6355.jpg ', '10973181 ', '6355.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/8/11/579.aspx ', '景星 ', '/shangpinf/Attachment/6344.jpg ', '10973181 ', '6344.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/8/11/578.aspx ', '前城国际花园 ', '/shangpinf/Attachment/6346.jpg ', '10973181 ', '6346.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/8/11/574.aspx ', '辰宇新村 ', '/shangpinf/Attachment/6321.jpg ', '10973181 ', '6321.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/8/11/573.aspx ', '青阳四季园 ', '/shangpinf/Attachment/6267.jpg ', '10973181 ', '6267.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/8/11/572.aspx ', '盛世华城 ', '/shangpinf/Attachment/6319.jpg ', '10973181 ', '6319.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/8/11/569.aspx ', '文轩阳光 ', '/shangpinf/Attachment/6272.jpg ', '10973181 ', '6272.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/8/11/568.aspx ', '金山小区 ', '/shangpinf/Attachment/6242.jpg ', '10973181 ', '6242.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/8/11/566.aspx ', '御路家园 ', '/shangpinf/Attachment/6132.jpg ', '10973181 ', '6132.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/8/11/564.aspx ', '青春公寓 ', '/shangpinf/Attachment/6232.jpg ', '10973181 ', '6232.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/8/11/559.aspx ', '环北家园三期 ', '/shangpinf/Attachment/6155.jpg ', '10973181 ', '6155.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/8/11/558.aspx ', '金禹花城 ', '/shangpinf/Attachment/6146.jpg ', '10973181 ', '6146.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/8/11/557.aspx ', '宏发财满街 ', '/shangpinf/Attachment/6122.jpg ', '10973181 ', '6122.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/8/11/555.aspx ', '环宇世纪星城 ', '/shangpinf/Attachment/6110.jpg ', '10973181 ', '6110.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/8/11/549.aspx ', '沈阳财富中心 ', '/shangpinf/Attachment/6011.jpg ', '10973181 ', '6011.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/8/11/548.aspx ', '嘉润中华园 ', '/shangpinf/Attachment/5936.jpg ', '10973181 ', '5936.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/8/11/547.aspx ', '春城雅苑 ', '/shangpinf/Attachment/5998.jpg ', '10973181 ', '5998.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/8/11/544.aspx ', '运恒国际 ', '/shangpinf/Attachment/5908.jpg ', '10973181 ', '5908.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/7/12/531.aspx ', '万和郦景 ', '/shangpinf/Attachment/5925.jpg ', '10973181 ', '5925.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/7/11/516.aspx ', '居适公寓 ', '/shangpinf/Attachment/6205.jpg ', '10973181 ', '6205.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/4/15/481.aspx ', '银港花园 ', '/shangpinf/Attachment/4648.jpg ', '10973181 ', '4648.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/4/15/479.aspx ', '阳光洛可可 ', '/shangpinf/Attachment/4652.jpg ', '10973181 ', '4652.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/4/15/476.aspx ', '环际花园 ', '/shangpinf/Attachment/4608.jpg ', '10973181 ', '4608.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/4/15/469.aspx ', '河畔花城 ', '/shangpinf/Attachment/4645.jpg ', '10973181 ', '4645.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/4/15/468.aspx ', '银亿•万万城 ', '/shangpinf/Attachment/4636.jpg ', '10973181 ', '4636.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/4/15/463.aspx ', '道义新城二期(瀚博西耶纳III期) ', '/shangpinf/Attachment/4600.jpg ', '10973181 ', '4600.jpg ');Group2[Groupcount2++] = new Array( '../h/2007/4/15/460.aspx ', '天空之城 (金奥新城三期) ', '/shangpinf/Attachment/4628.jpg ', '10973181 ', '4628.jpg ');var sum_item2 = Groupcount2-1; </script>
<script>
function getRandom2(){
if(counts2==sum_item2)
{
counts2=0;
return counts2;
}
else
{
counts2++;
return counts2;
}
}
[解决办法]
代码像浆糊一样.