posts to view prob

Started on the old forum in June 2009 · view the original in the archive · old links redirect here

5 replies · 487 views · started 17 years ago · 1 min read

5 participants
lee27 Developer · 63 posts #1

im tryin do it so need 20 forum posts to view links this wot im using

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

using name geordielee now

Vayne Developer · 106 posts #3

copy getposts function.

Nous Ne Dansos Pas, Nous Sommes Le Danse.!

blackhowk Senior · 411 posts #4

i dont want to copy this function because i dont use this script. i ask about what lee27 want...

i0nutzxp Developer · 150 posts #5

in core :

function numposts($uid)
{
   $howmuch = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_topics WHERE authorid='".$uid."'"));
  return $howmuch[0];
}

usage:

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'); ?>
something else Fellow · 2,296 posts #6

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

Sign in to reply.

Similar topics

Keyboard shortcuts

g f
Go to forums
g h
Go to your feed
g m
Go to messages
r
Reply (in a topic)
/
Search
j
Next post
k
Previous post
?
This list
Ctrl/⌘ + Enter
Send what you are writing
Ctrl/⌘ + B / I
Bold / italic while writing
Esc
Close