PLA Forums
Other Stuff That Has Little To Do With PLA => Techinical Shit => Technical Support => Topic started by: mr_doc on March 24, 2007, 02:45:15 PM
-
How do get the 'recent posts' of an SMF forum to show on another webpage in the same domain? I would like them to have just the subject showing, not the author, time, blah blah... An example of what I mean is:
http://www.phonelosers.org/
thanks
-
never mind, got it
-
Hey, you should post how you did it here. Not cause I'm interested, but cause I know that when I'm googling trying to figure out how to do something, I hate it when I get results back that are threads consisting entirely of the equivalent of the previous two posts.
-
SMF has that ability built in. That's why I chose to use SMF for the forums, because I knew it could be integrated into the rest of the site easily. Here's a page which shows all the things that are already set up for integration by SMF: http://www.phonelosers.org/forums/ssi_examples.php (http://www.phonelosers.org/forums/ssi_examples.php)
I just modify the SSI file to make changes to how it displays things.
-
Okay, I went to 'admin', 'news and newsletters', 'settings'
check the box next to 'Enable XML/RSS news (?)'
Then I went to http://rssfeedreader.com/ to customize the reader.
you have to give it an url to your forum. The info is here:
http://www.simplemachines.org/community/index.php?topic=25009.0
All of the XML content is accessed via the ".xml" action... To get RSS or RSS2 out of that (not viewable in most browsers), add ";type=rss" or ";type=rss2" to that URL.
The default feed is the 5 most recent posts:
http://www.simplemachines.org/community/index.php?action=.xml
There are several "sub-actions" available to this action, specifying exactly what to display:
Recent Posts (displays the most recent posts that you can see)
"Sub-action": recent
Default: Shows 5 most recent posts
Available options:
limit=x - display the "x" most recent posts (if number is less than 5, it will display 5. If number is larger than 255, it will display 255).
board=y - display only the recent posts from board "y"
Example: http://www.simplemachines.org/community/index.php?action=.xml;sa=recent;board=72;limit=10
News (displays the first post from the most recent topics that you can see)
"Sub-action": news
Available options:
limit=x - display only "x" items
board=y - display only news topics from board "y"
Example: http://www.simplemachines.org/community/index.php?action=.xml;sa=news;board=72;limit=10
Members (displays most recent members) - note: There is a bug in the current version of SMF that prevents this from working right - see Latest Members XML Problem for the fix
"Sub-action": members
Available options:
limit=x - display only the "x" most recent members
Example: http://www.simplemachines.org/community/index.php?action=.xml;sa=members;limit=10
Profile (displays the "profile summary" data in a nice XML feed for the specified user)
"Sub-action": profile
Required option:
u=x - display the profile info for user whose ID is "x"
Example: http://www.simplemachines.org/community/index.php?action=.xml;sa=profile;u=150
The output of http://rssfeedreader.com/ is going to be both php script and javascript so you can use whatever you want. You just throw that in your page and you're set.