修改要领如下:
1、把library/index_ad.lbi 里代码替换成以下代码:
<meta http-equiv="Content-Type" content="text/html; charset=gbk"><script type="text/javascript" src=http://down.chinaz.com/"http:/www.mfwine.cn/themes/Genuine/myFocus/myfocus-2.0.1.min.js"></script>
<script type="text/javascript">
//配置
myFocus.set({
id:'myFocus',//ID
pattern:'mF_pconline',//气势气魄
time:5//切换时距离断(秒)
});
</script>
<div id="myFocus"><!--核心图盒子-->
<div class="loading"><img src=http://down.chinaz.com/"themes/Genuine/myFocus/loading.gif" alt="请稍候..." /></div><!--载入画面(可删除)-->
<div class="pic"><!--图片列表-->
<ul>
<!--{foreach from=$index_adlist item=ads}-->
<li><a target="_blank" href=http://down.chinaz.com/"{$ads.url}"><img src="{$ads.content}" alt="{$ads.ad_name}" /></a></li><!--{/foreach}-->
</ul>
</div>
</div>
2、修改index.php
在“?>”前加上以下代码:
function get_index_ad(){$sql = 'SELECT ad_type,content,ad_name,url,orderid FROM ' . $GLOBALS['ecs']->table("ad_custom") .'ORDER BY orderid ASC' ;
$res = $GLOBALS['db']->getAll($sql);
$ads = array();
foreach ($res AS $adx => $row)
{
$ads[$adx]['ad_type'] = $row['ad_type'];
$ads[$adx]['content'] = $row['content'];
$ads[$adx]['url'] = $row['url'];
$ads[$adx]['ad_name'] = $row['ad_name'];
}
return $ads;
}
在这段代码
$smarty->assign('shop_notice', $_CFG['shop_notice']); // 商店通告后插手
$smarty->assign('index_adlist', get_index_ad());3、在“ecs_ad_custom”表下增加一个字段“orderid”
4、修改admin/flashplay.php
5、修改靠山模板 admin/templates 下的三个文件
flashplay_custom.htm
flashplay_custom_add.htm
flashplay_ccustom_edit.htm
第4与5步的修改打包下载地点: