【请教php】请热心人帮忙把一段php脚本转成 .Net脚本,非常感谢············

o07 2006-11-09 01:22:54

<script type="text/javascript">
<?

include ("conn.php");
$i=0;
$sql="select * from photo order by id desc limit 10";
$rs = mysql_query($sql);
while($rb=mysql_fetch_object($rs))
{
$i=$i+1;
print "imgUrl$i='/attachment/".$rb->photourl."'"."\r\n";
print "imgtext$i='".$rb->name."'"."\r\n";
print "imgLink$i='/djxu/ShowArticle.asp?ArticleID=".$rb->id."'"."\r\n";
}
?>
var focus_width=248
var focus_height=190
var text_height=16
var swf_height = focus_height+text_height
var pics=imgUrl1+"|"+imgUrl2
var links=imgLink1+"|"+imgLink2
var texts=imgtext1+"|"+imgtext2
document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" width="'+ focus_width +'" height="'+ swf_height +'">');
document.write('<param name="allowScriptAccess" value="sameDomain"><param name="wmode" value="transparent"><param name="movie" value="/skin/bbsou_com/bbsou2.swf"><param name="quality" value="high"><param name="bgcolor" value=#ffffff>');
document.write('<param name="menu" value="false"><param name=wmode value="opaque">');
document.write('<param name="FlashVars" value="pics='+pics+'&links='+links+'&texts='+texts+'&borderwidth='+focus_width+'&borderheight='+focus_height+'&textheight='+text_height+'">');
document.write('<embed src="/skin/bbsou_com/bbsou2.swf" wmode="opaque" FlashVars="pics='+pics+'&links='+links+'&texts='+texts+'&borderwidth='+focus_width+'&borderheight='+focus_height+'&textheight='+text_height+'" menu="false" bgcolor=#ffffff quality="high" width="'+ focus_width +'" height="'+ swf_height +'" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />');
document.write('</object>');
//-->
</script>
...全文
123 8 打赏 收藏 转发到动态 举报
写回复
用AI写文章
8 条回复
切换为时间正序
请发表友善的回复…
发表回复
job_2006 2006-11-10
  • 打赏
  • 举报
回复
只能说:倒
o07 2006-11-10
  • 打赏
  • 举报
回复
?
cangwu_lee 2006-11-09
  • 打赏
  • 举报
回复
只能说:晕

股神 2006-11-09
  • 打赏
  • 举报
回复
up
Aricc 2006-11-09
  • 打赏
  • 举报
回复
晕了
o07 2006-11-09
  • 打赏
  • 举报
回复

:)
jxdyzwh 2006-11-09
  • 打赏
  • 举报
回复
靠,太多了,眼睛都看花了
tete 2006-11-09
  • 打赏
  • 举报
回复
倒~眼都看花了
帮顶

代码分离的话,一般用
RegisterStartupScript()&RegisterClientScriptBlock()添加代码块

具体你自己写写吧,可以加深下映象

62,047

社区成员

发帖
与我相关
我的任务
社区描述
.NET技术交流专区
javascript云原生 企业社区
社区管理员
  • ASP.NET
  • .Net开发者社区
  • R小R
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告

.NET 社区是一个围绕开源 .NET 的开放、热情、创新、包容的技术社区。社区致力于为广大 .NET 爱好者提供一个良好的知识共享、协同互助的 .NET 技术交流环境。我们尊重不同意见,支持健康理性的辩论和互动,反对歧视和攻击。

希望和大家一起共同营造一个活跃、友好的社区氛围。

试试用AI创作助手写篇文章吧