The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
How to display blog RSS in a non-vb page
I am looking to display my blog RSS on my personal website via javascript or php. I have searched, but haven't found any code to do this like you can with the forum RSS.
Does anyone do this on their non-vb page, or know how to? |
#2
|
|||
|
|||
you may use curl. something like this
Code:
# INSTANTIATE CURL. $curl = curl_init(); # CURL SETTINGS. curl_setopt($curl, CURLOPT_URL, "http://www.musiciansgazette.com/blog_external.php?type=RSS2"); curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1); curl_setopt($curl, CURLOPT_CONNECTTIMEOUT, 0); # GRAB THE XML FILE. $xmlproduct-vbblog = curl_exec($curl); curl_close($curl); # SET UP XML OBJECT. $xmlObjproduct-vbblog = simplexml_load_string( $xmlproduct-vbblog ); $tempCounter = 0; foreach ( $xmlObjproduct-vbblog -> item as $item ) { # DISPLAY ONLY 10 ITEMS. if ( $tempCounter < 11 ) { echo "<li><a href=\"{$item -> guid}\">{$item -> title}</a></li> "; } $tempCounter += 1; } |
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|