Online privacy code

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Online privacy code

    i tried to do this but dont working...
    here is my online list..


    PHP Code:
    else if($action=="online")
    {

      
    addonline(getuid_sid($sid),"Online lista","");
        echo 
    "<card id=\"main\" title=\"ONLINE\">";
        
    $tmsg getpmcount(getuid_sid($sid));
      
    $umsg getunreadpm(getuid_sid($sid));
      if(
    $umsg>0)
      {
      echo 
    "<small>»<a href=\"inbox.php?action=main&amp;sid=$sid\">Privatne Poruke($umsg/$tmsg)</a><br/></small>";
      }

      
    //////ALL LISTS SCRIPT <<

        
    if($page=="" || $page<=0)$page=1;
        
    $num_items getnumonline(); //changable
        
    $items_per_page10;
        
    $num_pages ceil($num_items/$items_per_page);
        if(
    $page>$num_pages)$page$num_pages;
        
    $limit_start = ($page-1)*$items_per_page;

        
    //changable sql
        
    $sql "SELECT
                a.name, b.place, b.userid, sex , a.onlinemsg, a.plusses FROM ibwf_users a
                INNER JOIN ibwf_online b ON a.id = b.userid
                GROUP BY 1,2
                LIMIT 
    $limit_start$items_per_page
        "
    ;
        echo 
    "<p><small>";
        
    $mols mysql_fetch_array(mysql_query("SELECT name, value FROM ibwf_settings WHERE id='2'"));
        print 
    "Najvise online: <b>$mols[1]</b><br/>";
        
    $mols mysql_fetch_array(mysql_query("SELECT ppl, dtm FROM ibwf_mpot WHERE ddt='".date("d m y")."'"));
        print 
    "Najvise online danas: <b>$mols[0]</b><br/><br/>";
        
    $items mysql_query($sql);
        echo 
    mysql_error();
       while (
    $item mysql_fetch_array($items))
        {
          if (
    $item[3]=="M"){
          
    $icon "<img src=\"images/male.gif\" alt=\"M\"/>";
          }else
          if (
    $item[3]=="F"){
          
    $icon "<img src=\"images/female.gif\" alt=\"F\"/>";
          }
     if (
    $item[5]>="0"){
          
    $status "Novajlija!";
          }else
         if (
    $item[5]>"24"){
          
    $status "Mladji clan!";
          }
    if (
    $item[5]>"49"){
          
    $status "Pocetnik!";
          }
    if (
    $item[5]>"249"){
          
    $status "Stariji clan!";
          }
    if (
    $item[5]>"499"){
          
    $status "Dobar clan!";
          }
    if (
    $item[5]>"749"){
          
    $status "Super Clan";
          }
    if (
    $item[5]>"999"){
          
    $status "Dobar clan";
          }
    if (
    $item[5]>"1499"){
          
    $status "V.I.P";
          }
    if (
    $item[5]>"1999"){
          
    $status "Mator clan!";
          }
    if (
    $item[5]>"2499"){
          
    $status "Serbian World Kralj!";
          }
    if (
    $item[5]>"2999"){
          
    $status "No1!";
          }
    if (
    $item[5]>"4999"){
          
    $status "MATORA DRTINA!";
          }
    if (
    $item[5]>"3999"){
          
    $status "Serbian World Slatkish!";
          }
          
    $onlmsg parsepm($item[4], $sid);
          
    $lnk "<a href=\"index.php?action=viewuser&amp;who=$item[2]&amp;sid=$sid\">$item[0]</a>";
          echo 
    "$icon $lnk<br/><b>Status:</b> $status<br/>";

    $bre "SELECT showonline FROM ibwf_users WHERE name='".$item[0]."'";
    if (
    $bre[0]=1)
    {
    echo 
    "<b>Where:</b> $item[1] <br/>";
    }else
    if (
    $bre[0]=0)
    {
    echo 
    "<b>Online privacy!</b><br/>";
       }
    echo 
    "<b>Online message:</b> $onlmsg<br/><a href=\"inbox.php?action=sendpm&amp;who=$item[2]&amp;sid=$sid\">PP</a> | <a href=\"genproc.php?action=bud&amp;who=$item[2]&amp;sid=$sid&amp;todo=add\">PR</a><br/>--------<br/>";
    }
    echo 
    "</small></p>";
        echo 
    "<p align=\"center\">";
        if(
    $page>1)
        {
          
    $ppage $page-1;
          echo 
    "<a href=\"index.php?action=online&amp;page=$ppage&amp;sid=$sid\">«Nazad</a> ";
        }
        if(
    $page<$num_pages)
        {
          
    $npage $page+1;
          echo 
    "<a href=\"index.php?action=online&amp;page=$npage&amp;sid=$sid\">Napred»</a>";
        }
        echo 
    "<br/>$page/$num_pages<br/>";
        if(
    $num_pages>2)
        {
          echo 
    getjumper($action$sid,"index");
        }
        echo 
    "</p>";
      
    ////// UNTILL HERE >>

      
    echo "<p align=\"center\">";
      echo 
    "<a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo 
    "Home</a>";
      echo 
    "</p>";
      echo 
    "</card>";

    here is sql
    PHP Code:
    ALTER TABLE `ibwf_usersADD `showonlineINTNOT NULL 
    http://www.youtube.com/watch?v=vsLkpcFKbOk

    #2
    look at variable $bre
    http://www.youtube.com/watch?v=vsLkpcFKbOk

    Comment


      #3
      what u want the code to do m8 sorry u didnt give much info on this

      Comment


        #4
        i want to code something like private profile but i want to code this in online list... when i click on online list (in main page) i must see something like this: add this user as friend if u want to see him in future in online list. sorry for bad english
        http://www.youtube.com/watch?v=vsLkpcFKbOk

        Comment


          #5
          oh u want to make a code like

          rider+
          rap-4ever+
          user+
          user+
          user+

          when u click on the + or - it will remove the user from ur online list ?

          Comment


            #6
            noo i want to code something like this:

            rap-4ever
            Status: Baby
            Where: You must add this user as friend to see this

            ---

            rider
            Status: Moderator
            Where: Online list



            *user who see this,is firiend with rider but not friend with rap-4ever .
            Last edited by rap-4ever; 03.01.10, 18:38.
            http://www.youtube.com/watch?v=vsLkpcFKbOk

            Comment


              #7
              ohhh now i understand will have alook and see

              Comment


                #8
                i am glad to see that... i succes do code in genproc and index.php to hide and show this option but i have problem in online list.
                http://www.youtube.com/watch?v=vsLkpcFKbOk

                Comment


                  #9
                  just had a quick glance thru the code but should
                  Code:
                  $bre = "SELECT showonline FROM ibwf_users WHERE name='".$item[0]."'";
                  be
                  Code:
                  $bre = "SELECT showonline FROM ibwf_users WHERE name='".$item[2]."'";
                  Creator of
                  Epix.Mobi

                  Keep an Eye on us Big things coming soon!!!!
                  Need something for your site hit me up here

                  http://coding-talk.com/forum/main-fo...r-your-wapsite

                  Comment


                    #10
                    no mate...ur code is wrong
                    http://www.youtube.com/watch?v=vsLkpcFKbOk

                    Comment


                      #11
                      Originally posted by Loony View Post
                      just had a quick glance thru the code but should
                      Code:
                      $bre = "SELECT showonline FROM ibwf_users WHERE name='".$item[0]."'";
                      be
                      Code:
                      $bre = "SELECT showonline FROM ibwf_users WHERE name='".$item[2]."'";
                      maybe this
                      PHP Code:
                      $bre "SELECT showonline FROM ibwf_users WHERE id='".$item[2]."'"
                      Last edited by rap-4ever; 03.01.10, 23:57.
                      http://www.youtube.com/watch?v=vsLkpcFKbOk

                      Comment

                      Working...
                      X