Error last to post
Collapse
X
-
Originally posted by allan View Post$lpt=mysql_fetch_array(mysql_query("SELECT id, name FROM forumtopics WHERE fid='".$forum[0]."' ORDER BY lastpost DESC LIMIT 0,1"));
$main.="Last Post:<a href=\"./viewtopic.php?thread=$lpt[0]&go=last&sid=$sid\">$lpt[1]</a>(<a href=\"./profile.php?who=$pinfo[0]&sid=$sid\"$color>".getnick_uid($pinfo[0])."</a>)<br/>"; thats what iv got at the min mateCode:$sql=mysql_fetch_array(mysql_query("SELECT forumtopics.name,forumposts.uid,forumposts.thread FROM forumtopics INNER JOIN forumposts on forumtopics.id = forumposts.thread ORDER BY forumposts.id DESC LIMIT 1")); $a = htmlspecialchars($sql[0]); $sex=mysql_fetch_array(mysql_query("SELECT sex FROM profiles WHERE uid='$sql[1]'")); if($sex[0]=="M"){$color=" style=\"color:#00CC33\"";} if($sex[0]=="F"){$color=" style=\"color:#FF0066\"";} if($sex[0]==""){} $c = "<a href=\"forums/viewtopic.php?thread=$sql[2]&sid=$sid&go=last\">$a</a>"; $d = "<a href=\"profile.php?who=$sql[1]&sid=$sid\"$color><b>".getnick_uid($sql[1])."</b></a>"; $main.="Last post: $c By $d<br/>\n";
Leave a comment:
-
$lpt=mysql_fetch_array(mysql_query("SELECT id, name FROM forumtopics WHERE fid='".$forum[0]."' ORDER BY lastpost DESC LIMIT 0,1"));
$main.="Last Post:<a href=\"./viewtopic.php?thread=$lpt[0]&go=last&sid=$sid\">$lpt[1]</a>(<a href=\"./profile.php?who=$pinfo[0]&sid=$sid\"$color>".getnick_uid($pinfo[0])."</a>)<br/>"; thats what iv got at the min mate
Leave a comment:
-
have you procurred the $lpt and $pinfo array data ??Code:$lpt[0] $pinfo[0]
There must be somehing like
$lpt = my_sql_array ..........
$pinfo = my_sql_array ......
make sure you add these before you echo your code
Leave a comment:
-
$main.="Last Post: <a href=\"./fourms/viewtopic.php?thread=$lpt[0]&go=last&sid=$sid\">$lpt[1]</a>(<a href=\"../profile.php?who=$uid[0]&sid=$nick\"$color>".getnick_uid($pinfo[0])."</a>)<br/>\n"; all iv got mate
Leave a comment:
-
the code iv useing comes up like this Last Post: () not showing what the last post was iv tried every thing to try fix it but nothing seems to work
Leave a comment:
-
echo "Last Post: <a href=\"./viewtopic.php?thread=$lpt[0]&go=last&sid=$sid\">$lpt[1]</a>(<a href=\"../profile.php?who=$uid[0]&sid=$nick\"$color>".getnick_uid($pinfo[0])."</a>)<br/>\n";
lol
Leave a comment:
-
Error last to post
Hi there can any one help with last to post for wapdesire v2 on last to post i cnt seem to get it working.
$main.="Last Post: <a href=\"./viewtopic.php?thread=$lpt[0]&go=last&sid=$sid\">$lpt[1]</a>(<a href=\"../profile.php?who=$uid[0]&sid=$nick\"$color>".getnick_uid($pinfo[0])."</a>)<br/>\n";
i begreatful if any one can helpTags: None
Leave a comment: