标签名称:{$MY_网站通用Flash幻灯}
参数:频道ID,栏目ID,图片数量,flash宽度,flash高度
查询语句:
select top {input(2)} ArticleID,ChannelID,DefaultPicUrl from PE_Article where ChannelID={input(0)} and ClassID in ({input(1)}) and DefaultPicUrl<>'' and Deleted=false order by UpdateTime desc,ArticleID desc
标签内容:
<script type="text/javascript"> var swf_width={input(3)}; var swf_height={input(4)}; var config='3|0xffffff|0x0099ff|50|0xffffff|0x0099ff|0x000000'; //-- config 参数设置 -- 自动播放时间(秒)|文字颜色|文字背景色|文字背景透明度|按键数字颜色|当前按键颜色|普通按键色彩 -- var files = ""; var links = ""; var texts = ""; {Loop} {Infobegin} files = files == "" ? "{$InstallDir}{$Field(1,GetChannel,1)}/{$Field(1,GetChannel,3)}/{$Field(2,Text,0,0,0)}" : files + "|" + "{$InstallDir}{$Field(1,GetChannel,1)}/{$Field(1,GetChannel,3)}/{$Field(2,Text,0,0,0)}" links = links == "" ? "{$InstallDir}{$Field(0,GetUrl,Article,1)}" : links + "|" + "{$InstallDir}{$Field(0,GetUrl,Article,1)}" {Infoend} {/Loop} 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="'+ swf_width +'" height="'+ swf_height +'">'); document.write('<param name="movie" value="/Skin/images/focus.swf" />'); document.write('<param name="quality" value="high" />'); document.write('<param name="menu" value="false" />'); document.write('<param name=wmode value="opaque" />'); document.write('<param name="FlashVars" value="config='+config+'&bcastr_flie='+files+'&bcastr_link='+links+'&bcastr_title='+texts+'" />'); document.write('<embed src="/Skin/images/focus.swf" wmode="opaque" FlashVars="config='+config+'&bcastr_flie='+files+'&bcastr_link='+links+'&bcastr_title='+texts+'& menu="false" quality="high" width="'+ swf_width +'" height="'+ swf_height +'" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />'); document.write('</object>'); </script>
下载压缩后将focus.swf上传到Skin/images目录下面。
调用实例:{$MY_网站通用Flash幻灯(1011,10,5,450,300)}