<?php
	//必须登录才能浏览该页面
	require("foundation/auser_mustlogin.php");
	
	//引入公共模块
	require("foundation/fpages_bar.php");
	require("foundation/module_blog.php");
	require("foundation/fcontent_format.php");
	
	//语言包引入
	$b_langpackage=new bloglp;
	
	//变量定义
	$user_id=get_sess_userid();
	$user_mypals=get_sess_mypals();
	
	//当前页面参数
	$page_num=trim(get_argg('page'));
	
	//数据表定义  
	$t_blog=$tablePreStr."blog";
	$t_mypals=$tablePreStr."pals_mine";
	
	$blog_rs=array();
	$page_total='';
	if($user_mypals!=''){
		
		//读写分离定义方法
		$dbo=new dbex;
		dbtarget('r',$dbServs);
		
		$condition="user_id in ($user_mypals) and blog_limit<=1 and log_pass = 1 ";
		$order_by="order by log_id desc";
		$type="getRs";
		$dbo->setPages($set_page_data_num,$page_num);//设置分页
		$blog_rs=get_db_data($dbo,$t_blog,$condition,$order_by,$type);
		$page_total=$dbo->totalPage;//分页总数
  }
  
  	//控制数据显示
		$content_data_none="content_none";
		$content_data_set="";
		$isNull=0;
	if(empty($blog_rs)){
		$isNull=1;
		$content_data_none="";
		$content_data_set="content_none";
	}  
?>