JS图片切片的问题,紧急求救!!!!
这下边的图片地址和链接怎么从数据库里读出来
<SCRIPT type=text/javascript>
<!--
var focus_width=260
var focus_height=182
var text_height=25
var swf_height = focus_height+text_height
var pics= 'http://blog.cnknow.com/attachments/month_0603/3.jpg|http://blog.cnknow.com/attachments/month_0603/2.jpg|http://blog.cnknow.com/attachments/month_0603/1.jpg '
var links= 'http://cnknow.com/|http://cnknow.com/|http://cnknow.com/ '
var texts= '唐正东与莫科之争|江苏掀翻八一|巴特尔独木难支 '
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= "http://www.cnknow.com/images/media/pixviewer.swf "> <param name= "quality " value= "high "> <param name= "bgcolor " value= "#DADADA "> ');
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( ' </object> ');
//-->
</SCRIPT>
------解决方案--------------------在CS代码中公开一个属性
Public string ImageSrc
{
get
{
return ' '
}
}
然后JAVASCRIPT中var links= ' <%# ImageSrc %> '
------解决方案--------------------楼上手误,少个=
然后JAVASCRIPT中var links= ' <%# ImageSrc %> '
====>
然后JAVASCRIPT中var links= ' <%# =ImageSrc %> '