Mood Images

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

    Mood Images

    <div class='codetop'>CODE</div><div class='codemain' style='height:200px;white-space:pre;overflow:auto'>else if($action=="online")
    {

    addonline(getuid_sid($sid),"Online List","index.php?action=online");
    echo "<head>";
    echo "<title>Online List</title>";
    echo "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\">";
    echo "</head>";
    echo "<body>";
    //echo "<div><img src=\"../images/onlinelist.gif\" alt=\"Online List\"/></div>";
    echo popup($sid);
    //////ALL LISTS SCRIPT <<

    if($page=="" || $page<=0)$page=1;
    $num_items = getnumonline(); //changable
    $items_per_page= 10;
    $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,a.perm, b.place, b.userid 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 align=\"center\">";
    $items = mysql_query($sql);
    echo mysql_error();
    while ($item = mysql_fetch_array($items))
    {
    if($item[1]>&#39;0&#39;)
    {
    $tit = "";
    }if($item[1]==&#39;1&#39;)
    {
    $tit = "";
    }if($item[1]==&#39;2&#39;)
    {
    $tit = "";
    } if($item[1]==&#39;3&#39;)
    {
    $tit = "*";
    } if($item[1]==&#39;4&#39;)
    {
    $tit = "**";
    }


    $chtmood = mysql_fetch_array(mysql_query("SELECT img From ibwf_users WERE name=&#39;$chtmood[0]&#39;"));
    echo "<img src=\"$chtmood\"alt=\"(image)\"/>";}
    }else{
    $sex = mysql_fetch_array(mysql_query("SELECT sex FROM ibwf_users WHERE name=&#39;$item[0]&#39;"));
    if($sex[0]=="M"){$usersex = "<img src=\"../images/male.gif\" alt=\"(M)\"/>";}
    if($sex[0]=="F"){$usersex = "<img src=\"../images/female.gif\" alt=\"(F)\"/>";}
    if($sex[0]==""){$usersex = "";}
    if($item[1]>&#39;0&#39;)
    {
    $lnk = "$usersex<a href=\"index.php?action=viewuser&amp;who=$item[3]&amp;sid=$sid\">$tit$item[0]$tit</a>";
    }else{
    $lnk = "$usersex<a href=\"index.php?action=viewuser&amp;who=$item[3]&amp;sid=$sid\">$tit$item[0]$tit</a>";

    }
    echo "$lnk - $item[2]
    ";
    }
    //echo "</p>";
    //echo "<p align=\"center\">";
    if($page>1)
    {
    $ppage = $page-1;
    echo "<a href=\"index.php?action=online&amp;page=$ppage&amp ;sid=$sid\">«Prev</a> ";
    }
    if($page<$num_pages)
    {
    $npage = $page+1;
    echo "<a href=\"index.php?action=online&amp;page=$npage&amp ;sid=$sid\">Next»</a>";
    }
    echo "
    $page/$num_pages";
    if($num_pages>2)
    {
    echo getjumper($action, $sid,"index");
    }
    echo "</p>";
    ////// UNTILL HERE >>

    echo "<p align=\"center\">";
    echo "6 <a accesskey=\"6\" href=\"inbox.php?action=main&amp;sid=$sid\">Inbox</a>
    ";
    echo "7 <a accesskey=\"7\" href=\"lists.php?action=buds&amp;sid=$sid\">BuddyL ist</a>
    ";
    echo "8 <a accesskey=\"8\" href=\"index.php?action=chat&amp;sid=$sid\">Chatro oms</a>
    ";
    echo forumlink($sid,9);
    echo "0 <a accesskey=\"0\" href=\"index.php?action=main&amp;sid=$sid\"><img src=\"../images/home.gif\" alt=\"\"/>Home</a>";
    echo "</p>";
    echo "</body>";
    }
    else if($action=="viewpl")
    {</div>
    i need the part that is outlinded fixed up so that it requests the moods url from ibwf_moods so that a image is placed in from of the username in online users list

    #2
    when i feel like it lol
    Visit: Chat4u.mobi - The New Lay Of being a site of your dreams!
    Visit: WapMasterz Coming Back Soon!
    _______
    SCRIPTS FOR SALE BY SUBZERO
    Chat4u Script : coding-talk.com/f28/chat4u-mobi-script-only-150-a-17677/ - > Best Script for your site no other can be hacked by sql or uploaders.
    FileShare Script : coding-talk.com/f28/file-wap-share-6596/ -> Uploader you will never regret buying yeah it mite be old now but it still seems to own others...
    _______
    Info & Tips
    php.net
    w3schools.com

    Comment


      #3
      thakns sub btw the original code ome from chat.php ill paste that below ok
      might make it a bit easyer
      {
      $cmid = mysql_fetch_array(mysql_query("SELECT chmood FROM ibwf_users WHERE id=&#39;".$chat[0]."&#39;"));

      $iml = "";
      if(($cmid[0]!=0))
      {
      $mlnk = mysql_fetch_array(mysql_query("SELECT img, text FROM ibwf_moods WHERE id=&#39;".$cmid[0]."&#39;"));
      $iml = "<img src=\"$mlnk[0]\" alt=\"$mlnk[1]\"/>";

      }
      from what i can see thats it

      Comment

      Working...
      X