<?php
/*
'**************************************************************************************************
' 程序名称: CCTVAI开源音乐管理系统
' 官方网站: http://www.cctvai.com
' 联系 Q Q: 1542367792
' QQ交流群：136687984
' 版本：(终结版)
' 备注：未经书面授权，不得向任何第三方提供本软件系统！
' 功能，模板，插件，扩展，定制请联系QQ：1542367792
'**************************************************************************************************
*/
error_reporting(0);
?>
<link type="text/css" rel="stylesheet" href="css/list.css" /> 
<?php if($view==""){?>
   <div class="tag-list"> 
    <div class="tag-section">
	<a href="index.php?ac=friend" class="on tag-item"><span>我关注的</span></a>
	<a href="index.php?ac=friend&view=fans" class="tag-item"><span>关注我的</span></a>
    </div>  	
   </div> 
   <div class="user-hot"> 
    <div class="head"><strong>我关注的会员</strong></div>
<?php
$friendsql="select * from ".tname('friend')." where cd_hidden=0 and cd_uid='".$CcTvAi_com_userid."' order by UNIX_TIMESTAMP(CD_AddTime) desc";
$Arr=getuserpage($friendsql, 30); //sql,每页显示条数
$result=$db->query($Arr[2]);
$num=$db->num_rows($result);
if($num==0) {
		echo '<center>没有关注过任何会员</center>';
} else {
	if($result) {
		while($friend=$db->fetch_array($result)) {
			$user = $db->getrow("select cd_id,cd_nicheng,cd_sex,cd_logintime from ".tname('user')." where cd_id='".$friend['cd_uids']."'");
	echo'<div class="user-list"> 
    <ul class="list_con" id="yc_list_tj"> 
     <li> 
	 <a href="../singer/index.php?id='.$user['cd_id'].'" class="m_head"><img alt="" src="'.linkuserphoto($user['cd_id'], 120).'" width="60" height="60" /></a> 
	 <a href="../singer/index.php?id='.$user['cd_id'].'"> <h4>'.$user['cd_nicheng'].'</h4> <p><span>'.$user['cd_sex'].'</span><span>'.datetime($user['cd_logintime']).'登录</span></p> </a> </li> 
    </ul> 
    <div> 
    </div> 
   </div>';
}
} 
}
?>
<div class="page"><?php echo $Arr[0];?></div>
   </div>  
<?php }elseif($view=="fans"){?>
   <div class="tag-list"> 
    <div class="tag-section">
	<a href="index.php?ac=friend" class="tag-item"><span>我关注的</span></a>
	<a href="index.php?ac=friend&view=fans" class="on tag-item"><span>关注我的</span></a>
    </div>  	
   </div> 
   <div class="user-hot"> 
    <div class="head"><strong>关注我的会员</strong></div>
<?php
$friendsql="select * from ".tname('friend')." where cd_hidden=0 and cd_uids='".$CcTvAi_com_userid."' order by UNIX_TIMESTAMP(CD_AddTime) desc";
$Arr=getuserpage($friendsql, 30); //sql,每页显示条数
$result=$db->query($Arr[2]);
$num=$db->num_rows($result);
if($num==0) {
		echo '<center>没有会员关注你</center>';
} else {
	if($result) {
		echo'   <ul id="container"> ';
		while($friend=$db->fetch_array($result)) {
			$user = $db->getrow("select cd_id,cd_nicheng,cd_sex,cd_logintime from ".tname('user')." where cd_id='".$friend['cd_uid']."'");
	echo'<div class="user-list"> 
    <ul class="list_con" id="yc_list_tj"> 
     <li> 
	 <a href="../singer/index.php?id='.$user['cd_id'].'" class="m_head"><img alt="" src="'.linkuserphoto($user['cd_id'], 120).'" width="60" height="60" /></a> 
	 <a href="../singer/index.php?id='.$user['cd_id'].'"> <h4>'.$user['cd_nicheng'].'</h4> <p><span>'.$user['cd_sex'].'</span><span>'.datetime($user['cd_logintime']).'登录</span></p> </a> </li> 
    </ul> 
    <div> 
    </div> 
   </div>';
}
} 
}
?>
<div class="page"><?php echo $Arr[0];?></div>
   </div> 
<?php }?>