A5下载 - 努力做内容最丰富最安全的下载站!

A5站长下载站

当前位置:A5下载 > 源码技巧 > Ecshop > ecshop Warning: Illegal string offset 'cat_name' in

ecshop Warning: Illegal string offset 'cat_name' in

时间:2015-05-22 11:04作者:sa人气:3533

ecshop自定义栏目里,添加栏目报错Warning: Illegal string offset 'cat_name' in D:wampwwwyjy_shopadminnavigator.php on line 382

解决办法如下:

找到navigator.php文件下的function get_sysnav()

替换成

function get_sysnav()

{

global $_LANG;

$sysmain = array(

array($_LANG['view_cart'],'flow.php'),

array($_LANG['pick_out'],'pick_out.php'),

array($_LANG['group_buy_goods'],'group_buy.php'),

array($_LANG['snatch'],'snatch.php'),

array($_LANG['tag_cloud'],'tag_cloud.php'),

array($_LANG['user_center'],'user.php'),

array($_LANG['wholesale'], 'wholesale.php'),

array($_LANG['activity'], 'activity.php'),

array($_LANG['myship'], 'myship.php'),

array($_LANG['message_board'], 'message.php'),

array($_LANG['quotation'], 'quotation.php'),

);

$sysmain[] = array('-','-');

$catlist = array_merge(cat_list(0, 0, false), array('-'), article_cat_list(0, 0, false));

foreach($catlist as $key => $val)

{

if(is_array($val))

{

$val["view_name"] = $val["cat_name"];

for($i=0;$i<$val['level'];$i++)

{

$val["view_name"] = '&nbsp;&nbsp;&nbsp;&nbsp;' . $val["view_name"];

}

$val["url"] = str_replace( '&amp;', '&', $val["url"]);

$val["url"] = str_replace( '&', '&amp;', $val["url"]);

$sysmain[] = array($val["cat_name"], $val["url"], $val["view_name"]);

}

}

return $sysmain;

}

 

标签ecshop,Warning,Illegal,string

相关下载

查看所有评论+

网友评论

网友
您的评论需要经过审核才能显示

公众号