is_number($_REQUEST['u']) ? $_REQUEST['u'] : 1; $sql = "SELECT company,site_logo,history FROM " . $dou->table('admin') . " WHERE user_id = '$uid'"; $query = $dou->query($sql); $about = $dou->fetch_array($query); if(!is_array($about)||empty($uid)){ $dou->dou_msg('请不要做非法操作!', ''); exit; } $nav_middle_list = $dou->gets_nav('middle', '0', 'about', $id,'',$uid); foreach ($nav_middle_list as $key => $value) { //print_r($value[module].$key.'
'); if($value[module] == "about"){ $nav_middle_list[$key][cur] = '1'; } } $page['page_name'] = "发展历程"; $smarty->assign('company', $about['company']);//logo名称 $smarty->assign('site_logo', $about['site_logo']);//logo图片 $smarty->assign('site_url',$dou->get_nav_index($uid));//会员首页地址 // 赋值给模板-meta和title信息 $smarty->assign('page_title',$page['page_name'].'-'.$about['company'].'--'.$dou->page_title()); $smarty->assign('keywords', $about['company']); $smarty->assign('description', $about['company']); $smarty->assign('page_content', $about['history']); // 赋值给模板-导航栏 $smarty->assign('nav_top_list', $dou->gets_nav('top', '0', 'history', $id,'',$uid)); $smarty->assign('nav_middle_list', $nav_middle_list);//$dou->gets_nav('middle', '0', 'history', $id,'',$uid) $smarty->assign('nav_bottom_list', $dou->get_nav('bottom')); // 赋值给模板-数据 $smarty->assign('ur_here', $dou->ur_here('page', '', $page['page_name'], $uid,'nav')); $smarty->assign('page_list', $dou->get_page_list('0','0', $uid,'nav')); $smarty->assign('history', $page['page_name']); //$smarty->assign('top', get_page_info($top_id)); //$smarty->assign('page', $page); //if ($top_id == $id) //$smarty->assign("top_cur", 'top_cur'); $smarty->display('history.tpl'); /** * +---------------------------------------------------------- * 获取单页面信息 * +---------------------------------------------------------- */ function get_page_info($id = 0) { $query = $GLOBALS['dou']->select($GLOBALS['dou']->table('page'), '*', '`id` = \'' . $id . '\''); $page = $GLOBALS['dou']->fetch_array($query); if ($page) { $page['url'] = $GLOBALS['dou']->rewrite_url('page', $page['id']); } return $page; } ?>