程序特效有问题,请帮忙指点。
js特效问题,请帮忙解决。我做了一个js特效。可以实现我想要的效果,代码如下
<%
Dim retype,haha
haha="鼠标经过开始循环"
retype="鼠标离开还原静止"
%>
<body>
<table width="200" border="1" align="center" cellpadding="0" cellspacing="0" bordercolor="#F3F3F3">
<tr>
<td width="200" id="ss" align="center"><a href="123.asp"><div style="overflow: hidden;height: 20px; width: 200px;" onMouseOver="return showName('<%=haha%>');">鼠标离开还原静止</div></a>
</td>
</tr>
</table>
</body>
<Script language="javascript">
function showName(txt){
ss.innerHTML="<MARQUEE direction=left height=20 width=200 scrollamount=3 onMouseOut=\"return showNamew('<%=retype%>');\">"+txt+"</MARQUEE>";
}
function showNamew(txt){
ss.innerHTML="<div style='overflow: hidden;height: 20px; width: 200px;' onMouseOver=\"return showName('<%=haha%>');\">"+txt+"</div>";
//alert(ss.innerHTML);
}
</Script>
但是我加载到我想做的程序里就实现不了。程序如下
<Script language="javascript">
function showName(strid.txt){
var strid=id;
strid.innerHTML="<MARQUEE direction=left height=20 width=200 scrollamount=3 onMouseOut=\"return showNamew("+strid+",'"+txt+"');\"><div style='overflow: hidden;height: 20px; width: 200px;' onMouseOut=\"return showNamew("+strid+",'"+txt+"');\">"+txt+"</div></MARQUEE>";
}
function showNamew(strid,txt){
var strid=id;
strid.innerHTML="<div style='overflow: hidden;height: 20px; width: 200px;' onMouseOver=\"return showName("+strid+",'"+txt+"');\">"+txt+"</div>";
//alert(ss.innerHTML);
}
</Script>
Dim retitle,rtitle,rid
FUNCTION PageLeftClass (title,BigClassid,Order)
FkionEnd = ""
IF title <> "" AND BigClassid <>"" THEN
FkionSql="Select * From "& title &" Where BigClassid = " & BigClassid & " And Title <> '简介' Order By ClassOrder "& Order & ""
FkionRs.Open FkionSql,CONN,3,1
IF NOT FkionRs.Eof THEN
DO WHILE NOT FkionRs.Eof
retitle=LeftTrue(FkionRs("title"),26)
rtitle=FkionRs("title")
rid=FkionRs("smallclassid")
FkionEnd = FkionEnd & "<tr>"
FkionEnd = FkionEnd & "<td height='24' align='left' valign='top'><img src='images/product_dian.gif' width='9' height='9' /></td>"
if left(FkionRs("Link"),4)="http" then
FkionEnd = FkionEnd & "<td height='25' id=ss"&rid&" align='left'<div style='overflow: hidden;height: 20px; width: 200px;' onMouseOver='return showName('ss"&rid&"','"&rtitle&"');'><a href='"& FkionRs("Link") &"' title='"&FkionRs("title")&"'>" & retitle & "</a></div></td>" else
FkionEnd = FkionEnd & "<td height='25' id=ss"&rid&" align='left'><div style='overflow: hidden;height: 20px; width: 200px;' onMouseOver='return showName('ss"&rid&"','"&rtitle&"');'> <a href='"& FkionRs("Link") &"?bid="&FkionRs("bigclassid")&"&sid="&FkionRs("smallclassid")&"&Classname="&FkionRs("title")&"' title='"&FkionRs("title")&"'>" & retitle & "</a></div></td>"
end if
FkionEnd = FkionEnd & "</tr>"
FkionRs.MoveNext
LOOP
FkionRs.Close
END IF
END IF
PageLeftClass = FkionEnd
END FUNCTION
请高手帮我解决一下。谢谢 ,小弟在线等.......
[[italic] 本帖最后由 绝地逢生 于 2007-12-17 10:43 编辑 [/italic]]