The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
RSS feed as "info box"
Please pardon me if this has been answered elsewhere. I have searched extensively, but being new to vbulletin I fear my query words may not have hit their mark.
I am looking for something to take an RSS feed and place only the latest result set in a single location, overwriting any previous data. A perfect example of this behavior are the weather plug-ins. In my case, the RSS feed are the present ocean conditions at a given NOAA buoy (http://www.ndbc.noaa.gov/data/latest_obs/42039.rss) For reference, the problems I have experienced are: Stock RSS feed - Creates multiple threads or announcements. RSS as post - Creates one thread with lots of outdated, useless, data. Placing the feed in the announcements would work, *if* it each new update deleted the previous announcements. Any sugestions? Philip http://www.MexicoBeachTalk.com P.S. Unrelated thoughts/comments/criticisms on the site are welcome. |
#2
|
|||
|
|||
bump.
|
#3
|
||||
|
||||
Sounds interesting, but I must say I've never seen anything like this discussed before. I'm not sure exactly how I would go about it.
|
#4
|
|||
|
|||
I may not be describing it properly.
At the top of my site (and others), there is a box that displays the present weather (screenshot attached). The mod simply uses a vbCron job to pull an RSS feed from weather.com and stuffs it into a text file. When the user loads the page, the text file is read, reformated, and inserted into the DIV you see there. To locate the weather info, I just place the variable $weather into my template wherever I want the weather box to appear. What I am looking for is *exactly* like that, only it reads from a different RSS source and stuffs it into a different variable. What I'm getting is post after post (rss in post mod) where only the latest data is of any value. If there was a way to make that mod (or vB) delete the outdated posts, it would work fine as a post/thread/accnouncement. I have considered hacking the weather script to make it work, but I don't have any experience with vB add on and how they integrate. |
#5
|
||||
|
||||
I understand what you want. But, I think you will have to write a custom script to do this. Actually, an easy way may be to post the rss feed to a hidden forum and then post the post content on your page where you want it (query for the latest post in that forum). Make sure when you pull the post, you don't worry about permissions since it is in a hidden forum.
|
#6
|
|||
|
|||
That might work, but I'm not too keen on filling the DB with posts and having to manually clear it every so often.
I think I'll just try and hack the weather mod to permit two instances running. That's exactly what I need as this is sea conditions info vs. air conditions. I can't believe there isn't a mod like this for any generic RSS feed. It would be useful in a number of transient data applications such as a stock ticker, joke of the day, or any type of distributed announcement. --------------- Added [DATE]1253036733[/DATE] at [TIME]1253036733[/TIME] --------------- Success! Here's what I did; I took the add-on's php & xml files and and replaced every instance of "weather" with "seacond", checking to see if it made sense in context. I also replaced weather in all the filenames with seacond. Installed 'seacond' as per the instructions, and configured my new vbulletin option (and crontab) named "Seacond". Tested by replacing $weather in the navbar with $seacond, and it worked as expected. Since I couldn't find an unobtrusive place for the block of data, and it generally only applies to fishermen, I modified the navbar template to replace "weather" with "Seacond" in the fishing forum only. Navbar mod follows: PHP Code:
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|