|
案例新聞 |
//分頁顯示
$page_size = 7;
$sql = "select count(*) from news_info where newstype='anli' and state='1' order by newsid desc";
//取得總記錄數-$count
$result = mysql_query($sql,$dblink);
$myrow = mysql_fetch_array($result);
$amount = $myrow[0];
//echo $amount;
//計算總頁數-$page_count
if( $amount )
{
if( $amount < $page_size )
{
$page_count = 1;
} //如果總數據量小于$PageSize,那么只有一頁
if( $amount % $page_size )
{ //取總數據量除以每頁數的余數
$page_count = (int)($amount / $page_size) + 1; //如果有余數,則頁數等于總數據量除以每頁數的結果取整再加一
}
else
{
$page_count = $amount / $page_size; //如果沒有余數,則頁數等于總數據量除以每頁數的結果
}
}
//開始分頁顯示asdf
if($currentpage = $HTTP_GET_VARS["currentpage"])
{
}
else
{
$currentpage = 1;
}
if($currentpage <= 0)
{
$currentpage = 1;
}
if($currentpage >= $page_count)
{
$currentpage = $page_count;
}
//echo $currentpage;
$sql = "select newsid,newsname,newsdesc,MONTH(creatdate) as creatmonth,YEAR(creatdate) as creatyear,DAY(creatdate) as creatday from news_info where newstype='anli' and state='1' order by newsid desc limit " . ($currentpage-1)*$page_size . "," . $page_size;
$result = mysql_query($sql,$dblink);
//echo $sql;/
$newgif=0;
while($myrow = mysql_fetch_array($result))
{
$newgif++;
$newsid = $myrow["newsid"];
$newsname = $myrow["newsname"];
$newsdesc = $myrow["newsdesc"];
$creatyear = $myrow["creatyear"];
$creatmonth = $myrow["creatmonth"];
$creatday = $myrow["creatday"];
?>
 |
}}?> |
年月日 |
}?>
|
媒體報道 |
//分頁顯示
$page_size = 7;
$sql = "select count(*) from news_info where newstype='meiti' and state='1' order by newsid desc";
//取得總記錄數-$count
$result = mysql_query($sql,$dblink);
$myrow = @mysql_fetch_array($result);
$amount = $myrow[0];
//echo $amount;
//計算總頁數-$page_count
if( $amount )
{
if( $amount < $page_size )
{
$page_count = 1;
} //如果總數據量小于$PageSize,那么只有一頁
if( $amount % $page_size )
{ //取總數據量除以每頁數的余數
$page_count = (int)($amount / $page_size) + 1; //如果有余數,則頁數等于總數據量除以每頁數的結果取整再加一
}
else
{
$page_count = $amount / $page_size; //如果沒有余數,則頁數等于總數據量除以每頁數的結果
}
}
//開始分頁顯示asdf
if($currentpage = $HTTP_GET_VARS["currentpage"])
{
}
else
{
$currentpage = 1;
}
if($currentpage <= 0)
{
$currentpage = 1;
}
if($currentpage >= $page_count)
{
$currentpage = $page_count;
}
//echo $currentpage;
$sql = "select newsid,newsname,newsdesc,MONTH(creatdate) as creatmonth,YEAR(creatdate) as creatyear,DAY(creatdate) as creatday from news_info where newstype='meiti' and state='1' order by newsid desc limit " . ($currentpage-1)*$page_size . "," . $page_size;
$result = mysql_query($sql,$dblink);
$newgif=0;
while($myrow = @mysql_fetch_array($result))
{
$newgif++;
$newsid = $myrow["newsid"];
$newsname = $myrow["newsname"];
$newsdesc = $myrow["newsdesc"];
$creatyear = $myrow["creatyear"];
$creatmonth = $myrow["creatmonth"];
$creatday = $myrow["creatday"];
?>
 |
}}?> |
年月日 |
}?>
|
行業資訊 |
//分頁顯示
$page_size = 7;
$sql = "select count(*) from news_info where newstype='zixun' and state='1' order by newsid desc";
//取得總記錄數-$count
$result = mysql_query($sql,$dblink);
$myrow = @mysql_fetch_array($result);
$amount = $myrow[0];
//echo $amount;
//計算總頁數-$page_count
if( $amount )
{
if( $amount < $page_size )
{
$page_count = 1;
} //如果總數據量小于$PageSize,那么只有一頁
if( $amount % $page_size )
{ //取總數據量除以每頁數的余數
$page_count = (int)($amount / $page_size) + 1; //如果有余數,則頁數等于總數據量除以每頁數的結果取整再加一
}
else
{
$page_count = $amount / $page_size; //如果沒有余數,則頁數等于總數據量除以每頁數的結果
}
}
//開始分頁顯示asdf
if($currentpage = $HTTP_GET_VARS["currentpage"])
{
}
else
{
$currentpage = 1;
}
if($currentpage <= 0)
{
$currentpage = 1;
}
if($currentpage >= $page_count)
{
$currentpage = $page_count;
}
//echo $currentpage;
$sql = "select newsid,newsname,newsdesc,MONTH(creatdate) as creatmonth,YEAR(creatdate) as creatyear,DAY(creatdate) as creatday from news_info where newstype='zixun' and state='1' order by newsid desc limit " . ($currentpage-1)*$page_size . "," . $page_size;
$result = mysql_query($sql,$dblink);
$newgif=0;
while($myrow = @mysql_fetch_array($result))
{
$newgif++;
$newsid = $myrow["newsid"];
$newsname = $myrow["newsname"];
$newsdesc = $myrow["newsdesc"];
$creatyear = $myrow["creatyear"];
$creatmonth = $myrow["creatmonth"];
$creatday = $myrow["creatday"];
?>
 |
}}?> |
年月日 |
}?>
|
|
|