user additional info

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

    user additional info

    Hi there,


    How can I make if the user update the additional info to see on nick (on lavalair).
    exemple :

    user normal : joker
    user update addtion info : joker*

    Thanks
    Last edited by joker12; 12.05.10, 19:49.

    #2
    Your wording of your question isnt very clear. however I think you want a star to show next to the persons name if they have filled in additional profile details
    so something like this:
    PHP Code:
    $info = mysql_fetch_array(mysql_query("SELECT id FROM ibwf_xinfo WHERE uid='".$who."'"));
    if($info[0]>0){
    echo "joker*";
    }else{
    echo "joker";
    } 
    

    Comment


      #3
      not work

      I tried to put like you say but don`t work

      PHP Code:
                  //changable sql
                              if($view=="name")
                              {
                                  $sql = "SELECT id, name, regdate FROM ibwf_users ORDER BY name LIMIT $limit_start, $items_per_page";
                              }else{
                                  $sql = "SELECT id, name, regdate FROM ibwf_users ORDER BY regdate DESC LIMIT $limit_start, $items_per_page";
                              }
                          
                          
      
                          
                              $items = mysql_query($sql);
                              
                              if(mysql_num_rows($items)>0)
                              {
                              while ($item = mysql_fetch_array($items))
                              {
      
                              $info = mysql_fetch_array(mysql_query("SELECT id FROM ibwf_xinfo WHERE uid='".$$item."'"));
      if($info[0]>0){
      echo "$item*";
      }else{
      echo "$item";
      }  
                                $jdt = date("d-m-y", $item[2]);
                                $lnk = "<a href=\"index.php?action=viewuser&amp;who=$item[0]&amp;sid=$sid\">$item[1]</a> <small>Joined: $jdt</small>";
                                echo "$lnk<br/>"; 
      

      Comment


        #4
        Oh you want it on lists.php
        ... i was coding it for index.php

        you nearly got it right ...u just forgot to add which part of the array you were calling
        so just change lines:
        PHP Code:
        $info = mysql_fetch_array(mysql_query("SELECT id FROM ibwf_xinfo WHERE uid='".$$item."'"));
        if($info[0]>0){ 
        echo "$item*"; 
        }else{ 
        echo "$item"; 
        } 
        
        to
        PHP Code:
        $info = mysql_fetch_array(mysql_query("SELECT id FROM ibwf_xinfo WHERE uid='".$item[0]."'"));
        if($info[0]>0){ 
        echo "$item[1]*"; 
        }else{ 
        echo "$item[1]"; 
        } 
        

        Comment


          #5
          thx something else for help

          Comment


            #6
            your welcome

            Comment

            Working...
            X