Funmobile Avatar

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

    Funmobile Avatar

    I need code for view user avatar in the posts. Please help. p.s. jbg valjda ce neko skontati sta je pisac htio reci...

    #2
    use the code from view profile?

    Comment


      #3
      not work

      Comment


        #4
        the mood icons from chatrooms might work but i dotn realy see a point in doing it tbh would just add crap more script load for your users if you have images everywhere

        Comment


          #5
          Lavalair index.php

          //////////////////////////////////View Topic



          else if($action=="viewtpc")

          {

          addonline(getuid_sid($sid),"Viewing Forum Topic","");

          $tid = $_GET["tid"];

          $go = $_GET["go"];

          $tfid = mysql_fetch_array(mysql_query("SELECT fid FROM ibwf_topics WHERE id='".$tid."'"));

          if(!canaccess(getuid_sid($sid), $tfid[0]))

          {

          echo "<card id=\"main\" title=\"lavalair.net\">";

          echo "<p align=\"center\">";

          echo "You Don&#39;t Have A Permission To View The Contents Of This Forum

          ";

          echo "<a href=\"index.php?action=main&amp;sid=$sid\">Home</a>";

          echo "</p>";

          echo "</card>";
          getAd();
          echo "</wml>";

          exit();

          }



          $tinfo = mysql_fetch_array(mysql_query("SELECT name, text, authorid, crdate, views, fid, pollid from ibwf_topics WHERE id=&#39;".$tid."&#39;"));

          $tnm = htmlspecialchars($tinfo[0]);

          echo "<card id=\"main\" title=\"$tnm\">";

          echo "<p align=\"center\">";

          $num_pages = getnumpages($tid);

          if($page==""||$page<1)$page=1;

          if($go!="")$page=getpage_go($go,$tid);

          $posts_per_page = 5;

          if($page>$num_pages)$page=$num_pages;

          $limit_start = $posts_per_page *($page-1);

          echo "<a href=\"index.php?action=post&amp;sid=$sid&amp;tid= $tid\">Post reply</a>";

          $lastlink = "<a href=\"index.php?action=$action&amp;tid=$tid&amp;s id=$sid&amp;go=last\">Last Page</a>";

          $firstlink = "<a href=\"index.php?action=$action&amp;tid=$tid&amp;s id=$sid&amp;page=1\">First Page</a> ";

          $golink = "";

          if($page>1)

          {

          $golink = $firstlink;

          }

          if($page<$num_pages)

          {

          $golink .= $lastlink;

          }

          if($golink !="")

          {

          echo "
          $golink";

          }

          echo "</p>";

          echo "

          ";

          $vws = $tinfo[4]+1;

          $rpls = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_posts WHERE tid=&#39;".$tid."&#39;"));

          echo "Replies: $rpls[0] - Views: $vws
          ";

          ///fm here



          if($page==1)

          {

          $posts_per_page=4;

          mysql_query("UPDATE ibwf_topics SET views=&#39;".$vws."&#39; WHERE id=&#39;".$tid."&#39;");

          $ttext = mysql_fetch_array(mysql_query("SELECT authorid, text, crdate, pollid FROM ibwf_topics WHERE id=&#39;".$tid."&#39;"));

          $unick = getnick_uid($ttext[0]);

          if(isonline($ttext[0]))

          {

          $iml = "<img src=\"images/onl.gif\" alt=\"+\"/>";

          }else{

          $iml = "<img src=\"images/ofl.gif\" alt=\"-\"/>";

          }

          $usl = "
          <a href=\"index.php?action=viewuser&amp;sid=$sid&amp; who=$ttext[0]\">$iml$unick</a>";

          $topt = "<a href=\"index.php?action=tpcopt&amp;sid=$sid&amp;ti d=$tid\">*</a>";

          if($go==$tid)

          {

          $fli = "<img src=\"images/flag.gif\" alt=\"!\"/>";

          }else{

          $fli ="";

          }

          $pst = parsemsg($ttext[1],$sid);

          echo "$usl: [b]I NEED VIEW AVATAR HERE[/b] $fli$pst $topt
          ";

          $dtot = date("d-m-y - H:i:s",$ttext[2]);

          echo $dtot;

          echo "
          ";

          if($ttext[3]>0)

          {

          echo "<a href=\"index.php?action=viewtpl&amp;sid=$sid&amp;w ho=$tid\">POLL</a>
          ";

          }

          }

          if($page>1)

          {

          $limit_start--;

          }

          $sql = "SELECT id, text, uid, dtpost, quote FROM ibwf_posts WHERE tid=&#39;".$tid."&#39; ORDER BY dtpost LIMIT $limit_start, $posts_per_page";

          $posts = mysql_query($sql);

          while($post = mysql_fetch_array($posts))

          {

          $unick = getnick_uid($post[2]);

          if(isonline($post[2]))

          {

          $iml = "<img src=\"images/onl.gif\" alt=\"+\"/>";

          }else{

          $iml = "<img src=\"images/ofl.gif\" alt=\"-\"/>";

          }

          $usl = "
          <a href=\"index.php?action=viewuser&amp;sid=$sid&amp; who=$post[2]\">$iml$unick</a>";

          $pst = parsemsg($post[1], $sid);

          $topt = "<a href=\"index.php?action=pstopt&amp;sid=$sid&amp;pi d=$post[0]&amp;page=$page&amp;fid=$tinfo[5]\">*</a>";

          if($post[4]>0)

          {

          $qtl = "<a href=\"index.php?action=viewtpc&amp;sid=$sid&amp;t id=$tid&amp;pst=\">(quote:p=blaze,d=16-04-2006)</a>";

          }

          if($go==$post[0])

          {

          $fli = "<img src=\"images/flag.gif\" alt=\"!\"/>";

          }else{

          $fli ="";

          }

          echo "$usl: [b]I NEED VIEW AVATAR HERE[/b] $fli$pst $topt
          ";

          $dtot = date("d-m-y - H:i:s",$post[3]);

          echo $dtot;

          echo "
          ";

          }

          ///to here

          echo "</p>";

          echo "<p align=\"center\">";

          $tmsg = getpmcount(getuid_sid($sid));

          $umsg = getunreadpm(getuid_sid($sid));

          if($umsg>0)

          {

          echo "<a href=\"inbox.php?action=main&amp;sid=$sid\">Inbox( $umsg/$tmsg)</a>
          ";

          }

          if($page>1)

          {

          $ppage = $page-1;

          echo "<a href=\"index.php?action=viewtpc&amp;page=$ppage&am p;sid=$sid&amp;tid=$tid\">«PREV</a> ";

          }

          if($page<$num_pages)

          {

          $npage = $page+1;

          echo "<a href=\"index.php?action=viewtpc&amp;page=$npage&am p;sid=$sid&amp;tid=$tid\">Next»</a>";

          }

          echo "
          $page/$num_pages
          ";

          if($num_pages>2)

          {

          $rets = "Jump to page<input name=\"pg\" format=\"*N\" size=\"3\"/>";

          $rets .= "<anchor>[GO]";

          $rets .= "<go href=\"index.php\" method=\"get\">";

          $rets .= "<postfield name=\"action\" value=\"$action\"/>";

          $rets .= "<postfield name=\"tid\" value=\"$tid\"/>";

          $rets .= "<postfield name=\"sid\" value=\"$sid\"/>";

          $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";

          $rets .= "</go></anchor>";



          echo $rets;

          }

          echo "
          ";

          echo "<a href=\"index.php?action=post&amp;sid=$sid&amp;tid= $tid\">Post reply</a>";

          echo "</p>";

          echo "

          ";

          $fid = $tinfo[5];

          $fname = getfname($fid);

          $cid = mysql_fetch_array(mysql_query("SELECT cid FROM ibwf_forums WHERE id=&#39;".$fid."&#39;"));

          $cinfo = mysql_fetch_array(mysql_query("SELECT name FROM ibwf_fcats WHERE id=&#39;".$cid[0]."&#39;"));

          $cname = $cinfo[0];



          echo "<a href=\"index.php?action=main&amp;sid=$sid\">";

          echo "Home</a>&gt;";

          $cid = mysql_fetch_array(mysql_query("SELECT cid FROM ibwf_forums WHERE id=&#39;".$fid."&#39;"));

          if($cid[0]>0)

          {

          $cinfo = mysql_fetch_array(mysql_query("SELECT name FROM ibwf_fcats WHERE id=&#39;".$cid[0]."&#39;"));

          $cname = htmlspecialchars($cinfo[0]);

          echo "<a href=\"index.php?action=viewcat&amp;sid=$sid&amp;c id=$cid[0]\">";

          echo "$cname</a>
          ";

          }else{

          $cid = mysql_fetch_array(mysql_query("SELECT clubid FROM ibwf_forums WHERE id=&#39;".$fid."&#39;"));

          $cinfo = mysql_fetch_array(mysql_query("SELECT name FROM ibwf_clubs WHERE id=&#39;".$cid[0]."&#39;"));

          $cname = htmlspecialchars($cinfo[0]);

          echo "<a href=\"index.php?action=gocl&amp;sid=$sid&amp;clid =$cid[0]\">";

          echo "$cname Club</a>
          ";

          }

          $fname = htmlspecialchars($fname);

          echo "&gt;<a href=\"index.php?action=viewfrm&amp;sid=$sid&amp;f id=$fid\">$fname</a>&gt;$tnm";

          echo "
          </p>";
          getAd();
          echo "</card>";

          }

          Comment


            #6
            I need code for view user avatar in the posts. Please help. p.s. jbg valjda ce neko skontati sta je pisac htio reci...[/b]
            Add this code
            Code:
            $av = mysql_fetch_array(mysql_query("SELECT avatar FROM ibwf_users WHERE id=&#39;".$uid."&#39;"));
            echo "
            <img src=\"$av[0]\" alt=\"avatar\"/>
            between lines
            Code:
            $pst = parsemsg($ttext[1],$sid);
            AND

            Code:
                echo "$usl: $fli$pst $topt
            ";
            in index.php,you can put it where ever you want

            I tested this in last lavalair script that amylee posted on this forum
            druze valjda znas sta trebas....imas pozzzz

            Comment


              #7
              Add this code
              Code:
              $av = mysql_fetch_array(mysql_query("SELECT avatar FROM ibwf_users WHERE id=&#39;".$uid."&#39;"));
              echo "
              <img src=\"$av[0]\" alt=\"avatar\"/>
              between lines
              Code:
              $pst = parsemsg($ttext[1],$sid);
              AND

              Code:
                  echo "$usl: $fli$pst $topt
              ";
              in index.php,you can put it where ever you want

              I tested this in last lavalair script that amylee posted on this forum
              druze valjda znas sta trebas....imas pozzzz[/b]
              PozZ pa jesil ti ziv? rjesio sam problem na drugi nacin evo pogledaj http://united1x2.com/forum

              Comment

              Working...
              X