OpenCart - 中文论坛
标题:
想请教预设的最新商品(latest)模板的问题
[打印本页]
作者:
ny9889
时间:
2012-5-23 11:18
标题:
想请教预设的最新商品(latest)模板的问题
在catalog->controller->module->latest中
想请教一下,
function index($setting)中的$setting是从何而来?要从哪里trace?
谢谢,感激不尽!
<?php
class ControllerModuleLatest extends Controller {
protected function
index($setting)
{
//可直接調用$setting
$this->language->load('module/latest');
$this->data['heading_title'] = $this->language->get('heading_title');
$this->data['button_cart'] = $this->language->get('button_cart');
$this->load->model('catalog/product');
$this->load->model('tool/image');
$this->data['products'] = array();
$data = array(
'sort' => 'p.date_added',
'order' => 'DESC',
'start' => 0,
'limit' => $setting['limit']
);
……
}
?>
欢迎光临 OpenCart - 中文论坛 (https://bbs.opencart.cn/)
Powered by Discuz! X3.2