![]() |
Select first 5 database entries based on ID?
I have a RSS feeds that store the RSS data into the database. There are multiple feeds that are all identified by a feed id. (so cnn.com would be feed 1, tmz.com would be feed 2, etc...)
I want to select the and display the RSS feed on my forums based on the forum ID and have a default for areas that don't have a forum ID specified (ie...forumhome). I am hoping to display 5 results at a time I am pecking around VB.org and found the $result= $vbulletin->db->query_read("SELECT `feedID` , `ItemTitle` , `ItemLink` FROM `feedItems` WHERE feedID =1 LIMIT 5"); but I am unsure how to go about putting the results from $results into a variable and running a while loop. I also see that $results is a common variable to use, can I use another variable or is $results the best to use for vbulletin apps? Also - would the code for this be better in a plugin, or called from an external file via plugin? Thanks! ------------------------------------------------------------------- OK - I'm trying this but it's not working ...can someone help please? Code:
$query2 = $vbulletin->db->query_read( ----------------------------------------------------------------- Code:
$rss_get = $db->query_read("SELECT * FROM feedItems"); ---- ughh......this thing keeps merging my posts.... |
Change
PHP Code:
PHP Code:
|
sweet - than you very much!
I appreciate it! |
All times are GMT. The time now is 08:36 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|