zencart–LB又发现一个bug
问题是这样的,一级分类是
Cell Phones
二级分类:
- Multi Function Cell Phones
- Multi Function Cell Phones
- Refurbished Cell Phones
- Refurbished Cell Phones
- Chinese Brand Cell Phones
- 在首页就有了如下的显示:
Cell Phones
- Multi Function Cell Phones
- Multi Function Cell Phones
- Refurbished Cell Phones
- Refurbished Cell Phones
- Chinese Brand Cell Phones
More wholesale products >
这个时候问题就出来了,一级分类Cell Phones的地址和Chinese Brand Cell Phones,More wholesale products >
这个三个的地址居然一样了,实际情况应该是:Cell Phones和More wholesale products >的 他们俩的地址是一样,
模板放出者 太坏了!
如下放出修改方法:路径为:includes\modules\eatured_category_row.php
第48行的$cPath_new = str_replace(‘=0_’, ‘=’, $cPath_new);
下添加一句
$cPath_subs = $cPath_new . ‘=’ . $subcats->fields[categories_id];
然后60行开始的到64行之间的cPath_new全部替换为cPath_subs
问题解决!
有的这个文件 的行数可能不一样的,下面 我提供一下 要修改的代码
$subCatoryString .= ‘</dl><a href=”‘ . zen_href_link(FILENAME_DEFAULT, $cPath_new) . ‘”>More wholesale products ></a>’;
$list_box_contents[$row][$col] = array(‘params’ => ‘class=”categoryListBoxContents”‘,
‘text’ => ‘<div><a href=”‘ . zen_href_link(FILENAME_DEFAULT, $cPath_new) . ‘” title=”‘.SEO_COMMON_KEYWORDS.’ ‘.$featured_categories->fields['categories_name'].’”>’ . zen_image(DIR_WS_IMAGES . $featured_categories->fields['categories_image'], $featured_categories->fields['categories_name'], 148, 113) . ‘</a></div><h3><a href=”‘ . zen_href_link(FILENAME_DEFAULT, $cPath_new) . ‘” title=”‘.SEO_COMMON_KEYWORDS.’ ‘.$featured_categories->fields['categories_name'].’”>’. $featured_categories->fields['categories_name'] .’</a></h3>’.$subCatoryString);
上面这段代码里的cPath_new替换为cPath_subs,就好了
继续研究LB,希望发现BUG的能拿出来分享,感激大家一起完善它
老猫博客:http://laomao.info