circlesport

  博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理
是用的FLASH调用数据库的数据。代码如下:
<script type="text/javascript">
<!--


imgUrl1 = "http://www.moobol.com/livePic/manage/huxw/070225/083809_1.jpg";
imgText1 = "";
imgLink1 = escape("/molive/liveAction.do?method=findLiveList&liveId=12577");

imgUrl2 = "http://www.moobol.com/livePic/manage/kefeng/070224/000559_1.jpg";
imgText2 = "战士看美女";
imgLink2 = escape("/molive/liveAction.do?method=findLiveList&liveId=12661");

imgUrl3 = "http://www.moobol.com/livePic/manage/kefeng/070224/003118_1.jpg";
imgText3 = "沈阳商厦∶“有钱能使鬼推磨”";
imgLink3 = escape("/molive/liveAction.do?method=findLiveList&liveId=12650");

imgUrl4 = "http://www.moobol.com/livePic/manage/kefeng/070224/005915_1.jpg";
imgText4 = "直播福建省建阳农村婚礼习俗";
imgLink4 = escape("/molive/liveAction.do?method=findLiveList&liveId=12614");

imgUrl5 = "http://www.moobol.com/livePic/manage/kefeng/070224/010913_1.jpg";
imgText5 = "水源被污染 鱼儿就遭殃";
imgLink5 = escape("/molive/liveAction.do?method=findLiveList&liveId=12620");


var focus_width = 319;
var focus_height = 230;
var text_height = 18;
var swf_height = focus_height + text_height;
var pics = imgUrl1 + "|" + imgUrl2 + "|" + imgUrl3 + "|" + imgUrl4 + "|" + imgUrl5;
var links = imgLink1 + "|" + imgLink2 + "|" + imgLink3 + "|" + imgLink4 + "|" + imgLink5;
var texts = imgText1 + "|" + imgText2 + "|" + imgText3 + "|" + imgText4 + "|" + imgText5;
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="movie" value="/molive/webjsp/flash/pixviewer.swf"><param name="quality" value="high"><param name="bgcolor" value="#E3E3E3">');
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="/molive/webjsp/flash/pixviewer.swf" wmode="opaque" FlashVars="pics='+pics+'&links='+links+'&texts='+texts+'&borderwidth='+focus_width+'&borderheight='+focus_height+'&textheight='+text_height+'" menu="false" bgcolor="#E3E3E3" quality="high" width="'+ focus_width +'" height="'+ focus_height +'" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />');
document.write('</object>');
-->
</script>
你把那个FLASH用迅雷下载下来!然后把上述代码改动一下,就行了。
代码主要修改如下:
imgUrl1 = "http://www.moobol.com/livePic/manage/huxw/070225/083809_1.jpg";
imgText1 = "";
imgLink1 = escape("/molive/liveAction.do?method=findLiveList&liveId=12577");
用数据库提取5条相关记录。即:
循环开始
imgurl<%=k%>="rs("jilu")"
imgtext<%=k%>=rs("title")
imgLink<%=k%>=escape("<%=rs("url")%>")
循环结束

效果如下网址:
http://www.moobol.com/molive/homePageAction.do?method=findHomePage
posted on 2007-03-30 16:50  无极.net  阅读(6658)  评论(4编辑  收藏  举报