init_pageinfo();
$this->fenleiArr = array(
3 => array(1=>'酒类/饮品',2=>'食品/副食品',3=>'化妆品/日用品',4=>'服装/鞋帽',5=>'电子/耗材',6=>'文化/图书',7=>'其他行业'),
4 => array(21=>'防伪标签',22=>'防伪票证',23=>'防伪吊牌',24=>'RFID营销')
);
}
/**
* 初始化pageinfo
*/
private function init_pageinfo()
{
$base = $this->Base_model->row( array('id' => 1) );
$setting = $this->Setting_model->row( array('id' => 1) );
$this->pageinfo = array(
'isLogin' => FALSE,
'seo_title' => '',
'seo_keywords' => '',
'seo_desc' => '',
'csses' => array(),
'jses' => array(),
'breadcrumb'=> ''
);
$this->load->vars($setting);
$this->load->vars($base);
}
/**
* 设置页面title属性
* @param string $title
*/
protected function set_title($title='')
{
$this->pageinfo['seo_title'] = $title;
}
/**
* 设置页面keywords属性
* @param string $kw
*/
protected function set_keywords($kw='')
{
$this->pageinfo['seo_keywords'] = $kw;
}
/**
* 设置页面description属性
* @param string $desc
*/
protected function set_desc($desc='')
{
$this->pageinfo['seo_desc'] = $desc;
}
/**
* 添加js文件
* @param $js_file js文件名或者路径
* @param $is_rela_path true表示$js_file是相对路径,false表示自定义的绝对路径
*/
protected function add_js($js_file, $is_rela_path = true)
{
if($is_rela_path)
$this->pageinfo['jses'][] = 'static/js/' . $js_file;
else
$this->pageinfo['jses'][] = $js_file;
}
/**
* 添加css文件
* @param string $css_file css文件名或者路径
* @param bool $is_rela_path true表示$css_file是相对路径,false表示自定义的绝对路径
*/
protected function add_css($css_file, $is_rela_path = true)
{
if($is_rela_path)
$this->pageinfo['csses'][] = 'static/css/' . $css_file;
else
$this->pageinfo['csses'][] = $css_file;
}
/**
* 一维数组,设置面包屑导航
* @param array $sb
*/
protected function set_breadcrumb(array $sb)
{
$linker = " > ";
$str = '';
if(!$sb) $this->pageinfo['breadcrumb'] = '';
$j = 0;
foreach($sb as $key => $value)
{
$j=$j+1;
//$key = str_replace('-', ' ', $key);
if($value)
{
if($j==3 or $key=="客户案例"){
$str .= "[".$key ."]({$value})";
}else{
$str .= "[".$key ."]({$value})";
}
}else
{
$str .= "$key";
}
$str .= $linker;
}
$this->pageinfo['breadcrumb'] = rtrim($str, $linker);
}
/*判断是否登录*/
public function is_login($reture = TRUE)
{
if($reture)
{
if(!$this->sess->get('isLoginMember'))
{
echo WindowLocation(site_url('member/login'));
}
}
else
{
if($this->sess->get('isLoginMember'))
{
echo WindowLocation(site_url('member'));
}
}
}
}
/* file end */
Fatal error: Class 'Echina' not found in /usr/home/byu1182620001/htdocs/application/controllers/news.php on line 3