这是一个很多网站常用的JS滚动广告. 请问如果要动态的从数据库里面读取图片地址.URL链接和名称应该怎么写? 
以下附代码 
JScript code
   <!--
    var focus_width=190
    var focus_height=160
    var text_height=20
    var swf_height = focus_height+text_height    var pics='js/images/1.jpg|js/images/2.jpg|js/images/3.jpg|js/images/4.jpg|js/images/5.jpg|js/images/6.jpg'
    var links='http://www.elandkey.com|http://www.elandkey.com|http://www.elandkey.com|http://www.elandkey.com|http://www.elandkey.com|http://www.elandkey.com'
    var texts='1|2|3|4|5|6'    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="js/flash/cgal.swf"><param name="quality" value="high"><param name="bgcolor" value="#CCCCCC">');
    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="pixviewer.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="'+ focus_height +'" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />');        
    document.write('</object>');    //-->
// JavaScript Document这个是整个广告的源代码 
我先在JSP页面中实现 不是ASP中实现!!!