<? include("top.php") ?>
<div id="box"><!--主体-->
<div id="box_1"><!--主体1-->
<div id="box_1_left"><!--主体1:左-->
<div class="title">网站公告</div>
<div class="text"><?=de($gonggao)?></div>
</div><!--end 主体1:左-->
<div id="box_1_mid"><!--主体1:中-->

<div id="box_1_mid_title">
<?
foreach($list_i_flag as $k =>$v)
{
	$arr_i_flag[$v["t_name"]][]=$list_i_flag[$k];
}?>
<ul>
<? $j=1; foreach($arr_i_flag AS $k => $v){	?>
<li <?if($j==1) echo "class='curr'";?> id="tab1_btn_<?=$j?>" onMouseOver="tabit(this);"><?=$k?></li>
<? $j++;if($j>4) break;}?>
</ul>
</div>
<div id="clear-f"></div>

<? $j=1; foreach($arr_i_flag AS $k => $v){	?>
<div id="tab1_div_<?=$j?>" <?if($j!=1) echo 'style="DISPLAY: none"'?>>
<?$js=1; foreach($v as $ks =>$vs){
?>
<div id="tui_list" ><!--循环-->
<div class="left"><a href="<?=get_dir_url($vs['id'])?>" target="_blank"><img title="<?=$vs["title"]?>" alt="<?=$vs["title"]?>" src="<?=showPics($vs["pic"])?>" height="120" width="100" onerror="this.src='/images/nopic.jpg'"></a></div>
<div class="rig">《<?=strip_tags(de($vs["title"]))?>》<br><?=cut_str(strip_tags(de($vs["content"])),70)?></div>
</div><!--end 循环-->
<?$js++;if($js>4) break;}?>
</div>
<? $j++;if($j>4) break;}?>

</div><!--end 主体1:中-->
<div id="box_1_rig"><!--主体1:右-->
<div class="title">TOP 10</div>
<ul><?$j=1; foreach($list_D AS $k => $v){?>
<li><a href="<?=get_dir_url($v['id'])?>" target="_blank" title="<?=$v["title"]?>"><?=cut_str(de($v["title"]),10)?></a></li><?$j++;if($j>10) break;}?>                                                                              	
</ul> 
</div><!--end 主体1:右-->
</div><!--end 主体1-->
<div id="clear-f"></div>
<div id="box_gg">
<!--推荐gg-->
<script language="javascript" src="<?=INCLUDE_PATH?>/ad.php?act=showggtui"></script>
</div>
<!--gg-->
<div id="clear-f"></div>

<div id="box_2"><!--主体2-->


<?foreach($list_l_flag AS $k => $v){	?>
<div id="box_2_list"><!--主体:list-->
<div class="title"><a href="<?=$url_l_flag[$k]?>" target="_blank"><?=$titl_l_flag[$k]?></a></div><div id="clear-f"></div>
<div id="box_2_list_text">
<div class="left"><a href="<?=get_dir_url($v[0]['id'])?>" target="_blank" title="<?=$v[0]["title"]?>" alt="<?=$v[0]["title"]?>"><img src="<?=showPics($v[0]["pic"])?>" width="69" height="84" onerror="this.src='/images/nopic.jpg'"></a></div>
<div class="right">
<div><a href="<?=get_dir_url($v[0]['id'])?>" target="_blank" title="<?=$v[0]["title"]?>">《<?=$v[0]["title"]?>》</a></div>
<span><?=cut_str(de($v[0]["content"]),30)?> </span>
</div><div id="clear-f"></div>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<?foreach($v AS $ks => $vs){if($ks<=5 &&$ks!=0){	?>
  <tr>
    <td width="20%"><span><a href="<?=$url_l_flag[$k]?>" target="_blank">[<?=$titl_l_flag[$k]?>]</a></span></td>
    <td width="40%"><a href="<?=get_dir_url($vs['id'])?>" target="_blank" title="<?=$vs["title"]?>">《<?=cut_str(de($vs["title"]),7)?>》</a></td>
    <td width="40%"><?if($vs["writter_ext"]) {?>作者：<span><?=cut_str(de($vs["writter_ext"]),6)?><?}?></td>
  </tr>
  <?}}?>
</table>
</div>
</div><!--end 主体:list-->
<?}?>


</div><!--end 主体2--><div id="clear-f"></div>
<div id="box_gg">
<!--首页中部gg-->
<script language="javascript" src="<?=INCLUDE_PATH?>/ad.php?act=showggmain"></script>
</div>
<!--gg-->
<div id="clear-f"></div>
<div id="box_3"><!--主体3-->
<div id="box_3_left">
<div class="title">热门推荐</div>
<ul><?foreach($list_hot AS $k => $v){	?>
<li><a href="<?=get_dir_url($v['id'])?>" target="_blank" title="<?=$v["title"]?>"><?=cut_str(de($v["title"]),10)?></a></li><?}?>                                                                                          	
</ul> 
<div class="pic">
<!--首页左侧gg-->
<script language="javascript" src="<?=INCLUDE_PATH?>/ad.php?act=showggindexleft"></script>
</div>
<div class="title">点击排行<span><!--<a href="<?=BOOK_YM_PATH.'/'.$month_y;?>" target="_blank">更多..</a>--></span></div>
<ul>
<?foreach($list_M AS $k => $v){	?>
<li><a href="<?=get_dir_url($v['id'])?>" target="_blank" title="<?=$v["title"]?>"><?=cut_str(de($v["title"]),10)?></a></li><?}?>  
</ul>
</div>




<div id="box_3_mid">
<div class="title">NEW 最新章节</div>

<table width="100%" border="0" cellspacing="0" cellpadding="0">
<?$j=1;foreach($book_ext_list AS $k => $v){	?>
  <tr>
    <td width="15%"><span>[<?foreach($v["t_arr"] as $ks =>$vs){ echo '<a target="_blank" href='.rewrite_list_rule("type",$ks).'>'.$vs.'</a>';break;}?>]</span></td>
    <td width="30%"><a href="<?=get_dir_url($v['b_id'])?>" target="_blank" title="<?=$v["b_name"]?>"><?=cut_str(de($v["b_name"]),13)?></a></td>
    <td width=""><span><a href="<?=get_dir_url($v['b_id']).$v["id"].'.'.$html_ext?>" target="_blank" title="<?=sort_preg_replace($v["sort"],de($v["title"]))?>"><?=cut_str(sort_preg_replace($v["sort"],de($v["title"])),16)?></a></td>
    <td width="15%"><<?=dateMD($v["u_time"])?>></td>
  </tr>
  <?$j++;if($j>25) break;}?>
</table>
</div>
<div id="box_3_rig">
<div class="title">最近更新<span><a href='<?=rewrite_list_rule("list","news")?>'  target="_blank">更多..</a></span></div>
<ul>
<?foreach($list_new AS $k => $v){	?><li><a href="<?=get_dir_url($v['id'])?>" target="_blank" title="<?=$v["title"]?>"><?=cut_str(de($v["title"]),10)?></a></li><?}?>
</ul> 
<div class="pic">
<!--首页右侧gg-->
<script language="javascript" src="<?=INCLUDE_PATH?>/ad.php?act=showggindexright"></script>
</div>  
<div class="title">热门标签</div>
<ul>
<?foreach($list_tag AS $k => $v){	?>
<li><a alt="<?=$v["tag"]?>" title="<?=$v["tag"]?>" href="<?=rewrite_list_rule('tag',$v['id'])?>" target="_blank"><?=cut_str($v["tag"])?></a>(<?=$v["count"]?>)</li><?}?>                                                                    	      
</ul>
</div>

</div><!--end 主体3--><div id="clear-f"></div>




</div><!--end 主体-->
<? include("bot.php") ?>