Your IP : 216.73.216.170


Current Path : /home/zqegovsj/www/us3web.haibo.com.cn/newfinehome/
Upload File :
Current File : /home/zqegovsj/www/us3web.haibo.com.cn/newfinehome/news.php

<?php
include("function.php");

$aa='news.html';

$aaa=$lang['words'][73];

if($_GET['ntid']!='')
 
{$newstype=$db->selectarray("select id,name from ".$noe_version."_newstypes where id = ".$_GET['ntid']);

 

}else{ $newstype=$db->selectarray("select id,name from ".$noe_version."_newstypes order by id desc");



}

$newstype=$db->toarray($newstype);

if($_GET['ntid']!=''){ $pagekeyword.=$newstype[0][1].",".$company[5].",";

	$bb='newstype_'.$_GET['ntid'].'_'.$_GET['name'].'.html';

$bbb=$newstype[0][1];

	}

	

$pagekeyword=$newstype[0][1].", ".$company['2'];



if($_GET['nid']!=''){



$newinfo=$db->selectone("select id,title,created,content,type_id from ".$noe_version."_companynewses  where id = ".$_GET['nid']);



$newtypeinfo=$db->selectone("select id,name from ".$noe_version."_newstypes  where id ='".$newinfo[4]."'");


$bb='newstype_'.$newtypeinfo[0].'_'.$db->turn_name($newtypeinfo[1]).'.html';

$bbb=$newtypeinfo[1];

$newinfo[3]= stripslashes($newinfo[3]);

$newinfo[3]=html_entity_decode($newinfo[3]);



$pagekeyword=$newinfo[1].", ".$newtypeinfo[1].', '.$company[2];}

$pagekeyword2=$pagekeyword.', '.$company['8'].', '.$company['12'];

$pagekeyword3=$pagekeyword.', '.$company['8'].', '.$company['12']; 

include("head.php");

if($_GET['nid']!=''){

?>
<section class="well">
 <div class="container">
             <h1><?=$lang['words'][73]?></h1>
              
              <div class="row">
                   <article class="event-post col-md-12">
                        <!--Box-->
                        <div class="box-md">
                            <div class="box_left">
                                <time datetime="<?=date("y",$newinfo[2])?>-<?=date("m",$newinfo[2])?>-<?=date("d",$newinfo[2])?>" class="heading-2"><span><?=date("d",$newinfo[2])?></span> <?=date("M",$newinfo[2])?> / <?=date("Y",$newinfo[2])?></time>
                            </div>
                            <div class="box_cnt">
                                <h4><?=$newinfo[1]?></h4>

                                <p><?=$newinfo[3]?></p>
                                
								
								<ul class="row top_offset_2">
<?php 
$sql1="select id,title,created,type_id from ".$noe_version."_companynewses  where type_id='".$newinfo[4]."'  and id<'".$_GET['nid']."' order by id desc limit 0,1";
$rstmp1=$db->selectone($sql1);
?><?php if(!empty($rstmp1[0])) { ?><li class="col-sm-12">
                        <!--Box-->
                        <div class="box-md">
                            <div class="box_cnt">
                                <h5><a href="newsview_<?=$rstmp1[0]?>_<?=$db->turn_name($rstmp1[1])?>.html"><?=$lang['words'][162]?>: <?=$rstmp1[1]?></a></h5>

                            </div>
                        </div>
                        <!--END box-->
                    </li>
<?php } else { ?><?php }?>  


<?php 
$sql2="select id,title,created,type_id from ".$noe_version."_companynewses  where type_id='".$newinfo[4]."'  and id>'".$_GET['nid']."' order by id asc limit 0,1";
$rstmp2=$db->selectone($sql2);
?><?php if(!empty($rstmp2[0])) { ?><li class="col-sm-12">
                        <!--Box-->
                        <div class="box-md">
                           <div class="box_cnt">
                                <h5><a href="newsview_<?=$rstmp2[0]?>_<?=$db->turn_name($rstmp2[1])?>.html"><?=$lang['words'][163]?>: <?=$rstmp2[1]?></a></h5></div>
                        </div>
                        <!--END box-->
                    </li><?php } else { ?><?php }?>

                        </ul>	
						
						
						
                            </div>
                        </div>
                        <!--END box-->
                    </article>
</div>
		 

</div>	</section>					
		 <?php }else{?>


<section class="well">
            <div class="container">
                <h1 class="text-left"><?php if($_GET['ntid']==''){?><?=$lang['words'][73]?><?php }else{?><?=$newstype[0][1]?><?php }?></h1>

                <div class="row">
                
<?php if($_GET['ntid']==''){$newsnum2=$db->selectarray("select id,title,created  from ".$noe_version."_companynewses order by created desc");
}else{
$newsnum2=$db->selectarray("select id,title,created  from ".$noe_version."_companynewses where type_id =".$_GET['ntid']." order by created desc");
}


$newsnum2=$db->toarray($newsnum2);
$page_num=12;

$st=$_GET['st'];

if($_GET['page']!='')$st=$_GET['page']-1;

$pagecount=count($newsnum2);

if(!isset($st))$st=0;


global $build_creat;
$build_creat=1;
if($_GET['ntid']!=''){
$pages = $db->build_pagelinks(array(	'TOTAL_POSS'  => $pagecount,

							'PER_PAGE'    => $page_num,

							'CUR_ST'  => $st,
							'BASE_URL'    => "newstype_".$_GET['ntid']."_".$_GET['name']
)
);
}else{

$pages = $db->build_pagelinks3(array(	'TOTAL_POSS'  => $pagecount,

							'PER_PAGE'    => $page_num,

							'CUR_ST'  => $st,
							'BASE_URL'    => "news"
)
);
	
}

$number=$st*$page_num+1;

$number2=$st*$page_num+$page_num;

if($_GET['ntid']!=''){
	$sql = "select id,title,created,content  from ".$noe_version."_companynewses where type_id =".$_GET['ntid']." order by created desc  LIMIT ".$st*$page_num.','.$page_num;	
}else{
$sql = "select id,title,created,content  from ".$noe_version."_companynewses  order by created desc  LIMIT ".$st*$page_num.','.$page_num;
}	
$res=$db->selectarray($sql);

$news=$res;
$i=1; 
while(@$b=mysql_fetch_row($news)){?>

<article class="event-post col-md-6">
                        <!--Box-->
                        <div class="box-md">
                            <div class="box_left">
                                <time datetime="<?=date("y",$b[2])?>-<?=date("m",$b[2])?>-<?=date("d",$b[2])?>" class="heading-2"><span><?=date("d",$b[2])?></span> <?=date("M",$b[2])?> / <?=date("Y",$b[2])?></time>
                            </div>
                            <div class="box_cnt">
                                <h4><a href="newsview_<?=$b[0]?>_<?=$db->turn_name($b[1])?>.html"><?=$b[1]?></a></h4>

                                <p><?=$db->mystrcut(html_entity_decode($b[3]),100)?>...</p>
                                <a href="newsview_<?=$b[0]?>_<?=$db->turn_name($b[1])?>.html" class="subpage_btn btn_top_offset" data-text="<?=$lang['words'][153]?>">
                                    <?=$lang['words'][153]?>
                                </a>
                            </div>
                        </div>
                        <!--END box-->
                    </article><?php $i++;?>
<?php if(($i-1)%2==0){?></div><div class="row top_offset"><?php }?>							
<?php }?>  

<?php if($pagecount>12){?><div class="products_page"><?=str_replace('<a ','<a class="link-page" ',$pages)?></div><?php }?>
  </div>

                </div>

            </div>

        </section>
<?php }?>  
<?php include("foot.php");?>