当前位置:无线网络首页 >> 软件开发 >> 首页幻灯片尺寸调整
首页幻灯片尺寸调整
2009-09-19 02:07:55  作者:Farhill  来源:数码人家原创  浏览次数:476  文字大小:【】【】【
  • 简介:首页幻灯片尺寸可以调整,并且在火狐浏览器下幻灯片文字正常显示。

适用PHPCMS-2007SP6

将 ./templates/xhtml/phpcms/freelink_slide.html 文件

代码
<script language="JavaScript" src="{PHPCMS_PATH}include/js/flash.js" type="text/javascript"></script>
<script language="JavaScript" type="text/javascript">
<!--//--><![CDATA[//><!--
//注意:此flash焦点图必须保证图片数量为 4 幅,不可多不可少!
var pics="{$flash_pics}";
var mylinks="{$flash_links}";
var texts="{$flash_texts}";
var Flash = new Flash("{PHPCMS_PATH}images/flash.swf","Flash","240","230","5","#ffffff");
Flash.addParam("quality", "high");
Flash.addParam("salign", "t");
Flash.addVariable("p",pics);
Flash.addVariable("l",mylinks);
Flash.addVariable("icon",texts);
Flash.write("flash");
//--><!]]>
</script>

改为:
<script type="text/javascript">
//<![CDATA[
var interval_time=0; //图片停顿时间,单位为秒,为0则停止自动切换
var focus_width={$types[$type]['width']};
var focus_height={$types[$type]['height']};
var text_height=0;
var text_align="center" //标题文字对齐方式(left、center、right)
var swf_height=focus_height+text_height; //相加之和最好是偶数,否则数字会出现模糊失真的问题
var pics="{$flash_pics}";
var links="{$flash_links}";
var texts="{$flash_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="{PHPCMS_PATH}images/focus.swf" /><param name="quality" value="high" /><param name="bgcolor" value="#F0F0F0">');
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="{PHPCMS_PATH}images/focus.swf" wmode="opaque" FlashVars="pics='+pics+'&links='+links+'&texts='+texts+'&borderwidth='+focus_width+'&borderheight='+focus_height+'&textheight='+text_height+'" menu="false" bgcolor="#F0F0F0" 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>

0

顶一下

0

踩一下
相关文章
数码人家 | 版权声明 | 关于我们 | 友情链接 | 联系我们 | 广告服务

  • Copyright©2003-2015, 数码人家-网园 All Rights Reserved. 远山投姿欢迎您!
  •     陕ICP备05016083号-2