<?php
$conf_basedir	= "../../";	//相对主目录的位置
$conf_where		= "admin";	//选择调用相应模块
//$directory		= basename(dirname(__FILE__));	//定义当前所在的目录，引入模块公用函数
include_once($conf_basedir."base.inc.php");
checkAuth('39');	//判断登录和权限

$title = "房产热词管理-网络推广管理";
$admin = trim($admin);
$search_flag = 0;

//分页参数
$pagesize = 20 ;
$page_now = $page_now ? $page_now : 1;
//获得数据当前页面数据
$sql = "select count(*) as num from hot_word ;";
$total_num = $dbback->GetAll($sql);
$total_num = $total_num[0]['num'];
 
$page_total = ceil($total_num/20);
if ($page_now != '' && $page_now > $page_total) {
	$page_now = $page_total;
}elseif($page_now <  0){
	$page_now = 1;
}

$start = ($page_now-1)*20;
if($total_num <= 0 || $page_total <=0){
	$pages = 0 ;  //计算总页数
}else{
	$new_pagenavi = new_pagenavi2($page_now,$page_total,$total_num);
}
 // echo $new_pagenavi;die;

$sql = "select id,name,url from hot_word order by id desc  limit ".$start.",".$pagesize.";";
$data_info = $dbback->GetAll($sql);
 
//print_r($data_info);die;

//引用模版文件
include_once(Template("header"));
include_once(Template("promotion/index"));
include_once(Template("footer"));




?>