Example #1
0
 } else {
     if ($_REQUEST['json'] == 'getuser_finaocounts') {
         $userid = $_REQUEST['userid'];
         $actual_user_id = $_REQUEST['actual_user_id'];
         $totalfollowers = 0;
         $rows['totalfollowers'] = fngetTotalFollowers($userid);
         $totaltiles = 0;
         $rows['totaltiles'] = fngetTotalTiles_counts($userid, $actual_user_id);
         $totaltiles = 0;
         $sqlTilesCount = "SELECT user_tileid FROM `fn_user_finao_tile` ft JOIN fn_user_finao fu ON fu.`user_finao_id` = ft.`finao_id` WHERE ft.userid ='" . $userid . "' AND Iscompleted =0 AND finao_activestatus !=2  GROUP BY tile_id";
         //
         $sqlTilesCountRes = mysql_query($sqlTilesCount);
         $rows['totaltiles'] = mysql_num_rows($sqlTilesCountRes);
         $rows['totaltiles'] = fngetTotalTiles_counts($userid, $actual_user_id);
         $totalfinaos = 0;
         $rows['totalfinaos'] = fngetTotalFinaos($userid, $actual_user_id);
         $totalfollowings = 0;
         $rows['totalfollowings'] = fngetTotalFollowings($userid);
         $json = array();
         $json['res'] = $rows;
         echo json_encode($json);
     } else {
         if ($_REQUEST['json'] == 'homepage_user') {
             $userid = $_REQUEST['userid'];
             $data = getHomePageDetailsByUser($userid);
             echo $data;
         } else {
             if ($_REQUEST['json'] == 'finao_list') {
                 $myid = $_REQUEST['userid'];
                 $type = $_REQUEST['type'];
                 $otherid = 0;
Example #2
0
function getuser_finaocounts($userid, $actual_user_id)
{
    $totalfollowers = 0;
    $rows['totalfollowers'] = fngetTotalFollowers($userid);
    $totaltiles = 0;
    $rows['totaltiles'] = fngetTotalTiles_counts($userid, $actual_user_id);
    $totaltiles = 0;
    $sqlTilesCount = "SELECT user_tileid FROM `fn_user_finao_tile` ft JOIN fn_user_finao fu ON fu.`user_finao_id` = ft.`finao_id` WHERE ft.userid ='" . $userid . "' AND Iscompleted =0 AND finao_activestatus !=2  GROUP BY tile_id";
    $sqlTilesCountRes = mysql_query($sqlTilesCount);
    $rows['totaltiles'] = mysql_num_rows($sqlTilesCountRes);
    $rows['totaltiles'] = fngetTotalTiles_counts($userid, $actual_user_id);
    $totalfinaos = 0;
    $rows['totalfinaos'] = fngetTotalFinaos($userid, $actual_user_id);
    $totalfollowings = 0;
    $rows['totalfollowings'] = fngetTotalFollowings($userid);
    $json = array();
    $json['res'] = $rows;
    echo json_encode($json);
}