skter4938
07-23-2006, 05:50 AM
Hello,
How can a query all of the threads from a certain forum on a php page?
-Artem
How can a query all of the threads from a certain forum on a php page?
-Artem
Thank you for visiting. This is our website archive. Please visit our main website by clicking the banner above. vBulletin FAQ is dedicated to helping the forum owner build, manage and profit from his vBulletin Forum vBulletin Web Hosting - Free skins and styles for your vBulletin - Search Engine Optimization |
|
|
|
|
Query helpskter4938 07-23-2006, 05:50 AM Hello, How can a query all of the threads from a certain forum on a php page? -Artem que 07-31-2006, 10:34 AM It may look something like this: "SELECT * FROM threads WHERE ForumID = $ForumID AND ThreadType = "normal" ORDER BY DateLastPost"; skter4938 07-31-2006, 04:13 PM hmmm this is my code <?php //Database connection $sql = "SELECT * FROM threads WHERE 2 = $ForumID AND ThreadType = 'normal' ORDER BY DateLastPost"; $result = mysql_query($sql); while ($row = mysql_fetch_assoc($result)) { echo '<tr><td>'; echo $row['title']; echo '</td></tr>'; } ?> And it gives me this error: Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/webtodes/public_html/chilledsaladfork/index.php on line 44 que 08-04-2006, 03:07 PM There could be a few ways to deal with threads... SELECT forum.forumid, lastpost, lastposter, lastthread, lastthreadid, threadcount FROM forum AS forum skter4938 08-04-2006, 03:18 PM Now it just shows nothing. I'm sorry for not being able to get this, I'm not too good with php and MySQL | |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 |
|
EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum