posts to view prob

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

    posts to view prob

    im tryin do it so need 20 forum posts to view links this wot im using
    Code:
    If(getposts(getuid_sid($sid))<20)
    {
    $posts = $info["posts"];
    echo "you need 20 posts to view links<br/>";
    }
    else
    {
    echo "<b></b><a accesskey=\"9\" href=\"linksites.php?sid=$sid\"> Links</a><br/>";
    }
    prob is it shows you need 20 posts even when done over 20 iv tried all ways and cnt get it to work any help b great

    #2
    what posts? old posts? last 20 new posts? random 20 posts?
    http://ngeo.ro

    Comment


      #3
      copy getposts function.
      Nous Ne Dansos Pas, Nous Sommes Le Danse.!

      Comment


        #4
        i dont want to copy this function because i dont use this script. i ask about what lee27 want...
        http://ngeo.ro

        Comment


          #5
          in core :
          PHP Code:
          function numposts($uid)
          {
             
          $howmuch mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_topics WHERE authorid='".$uid."'"));
            return 
          $howmuch[0];

          usage:
          PHP Code:
          If(numposts(getuid_sid($sid))<20)
          {
          //$posts = $info["posts"];
          echo "This link ask you for 20 posts on forum. You have only ".numposts(getuid_sid($sid))." <br/>";
          }
          else
          {
          echo 
          "<b></b><a accesskey=\"9\" href=\"linksites.php?sid=$sid\"> Links</a><br/>";

          <?php unlink('World/Europe/Romania.country'); ?>

          Comment


            #6
            above code is for number of topics not post total ibwf_posts + ibwf_topics might be better

            Comment

            Working...
            X