The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
![]()
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( "SELECT feedID , ItemTitle , ItemLink FROM feedItems WHERE feedID =1 LIMIT 5"); while ($rssres = $db->fetch_array($query2)) { $latestrss = $rssres['ItemTitle'] <br />; } ----------------------------------------------------------------- Code:
$rss_get = $db->query_read("SELECT * FROM feedItems"); while ($subcat = $db->fetch_array($rss_get)) { $rss_feed = $subcat["ItemTitle"]; } ---- ughh......this thing keeps merging my posts.... |
#2
|
|||
|
|||
![]()
Change
PHP Code:
PHP Code:
|
#3
|
|||
|
|||
![]()
sweet - than you very much!
I appreciate it! |
![]() |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|