Does anyone see a reason why the "show news comments" section of this code is only displaying the newest comment for each post?
$comments_list_commentbit is being called from within the template for "news_newsbit_commentslink". Note that some classes and variables may not appear to be defined as this is only a portion of the script.
$newslimit is set to 50 currently. 6 of 6 test news posts are displayed, its just the comments for each post that aren't displaying all the results when called from outside the loop.
are you sure that you get the right newsid out of the news?
The query "SELECT * FROM `unp_comments` WHERE newsid='$newsid'"
is responsable for the output of the comments belonging to the news and
newsid seems to be the glue for both.
(note the ".") will output all the comments for each news post, but it will also include the comments of the post above it. Why might this be? This notice is also passed at the top of the script output so long as the first post has 1 or more comments:
Code:
Notice: Undefined variable: comments_list_commentbit in /home/x/x/x.com/news/news.php(149) : eval()'d code on line 8