| Current Path : /home/zqegovsj/www/us3web.haibo.com.cn/beiresthetic/ |
| Current File : /home/zqegovsj/www/us3web.haibo.com.cn/beiresthetic/news2.php |
<?php
include("function.php");
$page = !empty($_GET['st']) ? (int)$_GET['st'] : 1;
$limit = 12; // 每页显示的数量
$offset = ($page - 1) * $limit; // 计算偏移量
$num =$db->selectone( "select count(id) from ".$noe_version."_companynewses where member_id='".$id."' and type_id =".$_GET['ntid']." ");
$pagecount=$num[0];
if(!isset($st))$st=1;
$number=($st-1)*$limit+1;
$number2=($st-1)*$limit+$limit;
$total_pages = ceil($pagecount / $limit);
$sql = "select id,title,created,content,picture,title2 from ".$noe_version."_companynewses where member_id='".$id."' and type_id =".$_GET['ntid']." order by created desc LIMIT ".($st-1)*$limit.','.$limit;
$res=$db->selectarray($sql);
$news=$res;
$cate=$db->selectone( "select id,name,name2,keyword,des from ".$noe_version."_newstypes where id='".$_GET['ntid']."'");
$aa='news.html';
$aaa=$lang['words'][73];
$bb=$db->turn_name($cate[2]).'_newstype'.$cate[0].'.html';
$bbb=$cate[1];
$purl=$bb;
$urlsort=$db->turn_name($cate[2]).'_newstype'.$cate[0];
$pagekeyword=$cate[1];
$pagekeyword2=$pagekeyword;
$pagekeyword3=$pagekeyword;
include("head.php");
?><div class="n_main">
<div class="container">
<? include("a_left.php");?>
<div class="n_right">
<div class="news">
<ul class="clearfix">
<? $i=1; while(@$b=mysqli_fetch_row($news)){
?>
<li>
<div class="li clearfix">
<div class="img">
<a href="/<?=$db->turn_name($b[5])?>_newsview<?=$b[0]?>.html">
<picture>
<img src="https://<?=$imgprod?>/upload/middle/<?=$b[4]?>" alt="<?=$b[1]?>">
</picture>
</a>
</div>
<div class="text">
<h3 class="p-b-20 p-t-10"><a href="/<?=$db->turn_name($b[5])?>_newsview<?=$b[0]?>.html" class="title dark-color font-bold font-22px"><?=$b[1]?></a></h3>
<div class="news_day"><span><i class="fa fa-calendar"></i><?=date("d",$b[2])?> <?=date("M",$b[2])?>, <?=date("Y",$b[2])?></span></div>
<div class="text"><?=$db->mystrcut(html_entity_decode($b[3]),210)?>..</div>
<a href="/<?=$db->turn_name($b[5])?>_newsview<?=$b[0]?>.html" class="my_more1">Learn More</a>
</div>
</div>
</li>
<? $i++;?>
<? }?>
</ul>
<? if($pagecount>12){?>
<div class="page_num clearfix">
<? include("page_navigation.php");?>
</div>
<? }?>
</div>
</div>
</div>
</div>
<? include("foot.php");?>