<?php
/**
* 中国鞋网 | >>> 关于我们 | 成功案例 <<< |
*
www.chinashoes.cc about file
* @author angelover |
moolao@gmail.com * @version 3.0 $Id 2007-02-03 09:14:57
*/
require_once($_SERVER['DOCUMENT_ROOT']."/Sys_Config.inc.php");
require_once(SYS_PATH."/comm/Class.Public.SearchFunc.php");
require_once(SYS_PATH."/comm/lib_comm.inc.php");
$smarty->caching = TRUE;
if (!$smarty->is_cached('about/success.tpl', $cache_id))
{
/* SQL检索扩展 */
$ext = isset($_REQUEST['lb']) && trim($_REQUEST['lb']) <> "" ? " AND lb = '$_REQUEST[lb]' " : " ";
/* 获取条目总数 */
$count = $conn->Getone(" SELECT COUNT(*) FROM _csM_success WHERE 1 ".$ext);
/* 获取信息列表 */
$arr = array();
$page = isset($_REQUEST['page']) && intval($_REQUEST['page']) > 0 ? $_REQUEST['page'] : 1;
$size = 15;
$sql = "SELECT id, site_name, tele, url, com_intro, image FROM _csM_success WHERE 1 ".$ext;
$res = $conn->SelectLimit($sql, $size, ($page-1) * $size );
$arr = array();
if($res){
while ($row = $res->FetchRow()){
$arr[$row['id']]['id'] = $row['id'];
$arr[$row['id']]['site_name'] = $row['site_name'];
$arr[$row['id']]['tele'] = $row['tele'];
$arr[$row['id']]['url'] = $row['url'];
$arr[$row['id']]['com_intro'] = $row['com_intro'];
$arr[$row['id']]['image'] = $row['image'];
}
}
$smarty->assign('successfuc_list', $arr);
/* 分页显示 */
assign_pager('?tmp=4.html', $_REQUEST['id'], $count, $size, '', '', $page);
}
$smarty->display('about/success.tpl', $cache_id);
?>