Hiya, I have a site with a PHPBB board, I want to put the 10 most popular posts on my site homepage, anybody got a link or piece of script that will let me do this? Thanks, Tomred
How would you define "10 most popular posts"? Edit: It says "topics" in the title so I guess this could work: $result = mysql_query("SELECT topic_id, topic_title FROM phpbb_topics ORDER BY topic_replies DESC LIMIT 10"); echo '<ul>'; while($row = mysql_fetch_array($result)) { echo '<li>'; echo '<a href="/phpBB/viewtopic.php?t=' . $row['topic_id'] . '">' . $row['topic_title'] . '</a>'; echo '</li>'; } echo '</ul>'; PHP:
That's exactly what I'm talking about! I dont know much about PHP though, if I just paste that into my index.php will it work?
It should work. Just check if your "phpbb table prefix" is really "phpbb_". If not, replace "phpbb_" in "phpbb_topics" with the prefix you used. You should also replace "phpBB" with the board folder name in case it's not "phpBB".