The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
vB Weather Mk. 2 Details »» | |||||||||||||||||||||||||
This is a post of a much-revised hack originally posted (by myself) here. I am posting this as a new hack because MSNBC, who the raw weather data is provided through, has changed their source provider (from AccuWeather to The Weather Channel), which required a retooling of the data parsing code, as well as completely new databases. I have also made obsolete the weather_functions.php file, moving the functions to admin/functions.php, simplifying the ability to show current weather data on any page (if desired). Finally, in what I'm sure will be welcome news to many people who have installed the original, I've completely rewritten the instructions, making them, as far as I can tell, much simpler.
If you are unfamiliar with the original: This hack provides current weather conditions and a five-day forecast to your members. Each member can select from over 34,000 cities, by narrowing down from region (like continents), country, and subdivision (like states). Each member can also select to see temperatures in Fahrenheit or Celsius, as well as metric or standard measurements for the other data. A demo is available on my test board: http://www.jjr512.com/testboard/. I have set up an account for anyone to use to test it out (username: test; pw: test). If you are not logged in, you will see default weather on the home page (default is set to New York City), and cannot change settings (I forget if you can view a detailed forecast, though; you may be able to). If you do log in, you can change the settings for the test account, to see how it works. *** If you have installed any previous version, you should completely uninstall it. Read the instructions and work backwards from there: Delete all templates added, remove changes to any existing templates (I forget if there were any or not), delete all new tables from the database, delete all new files added by the old hack. All have been changed to some extent, some more than others, and it would be easier to work from a clean slate. Especially since some of the template names have changes, so if you don't delete the old ones, they'll just be sitting there doing nothing at all. It is also vitally important to delete (or "drop") the tables--I believe there were six--you added for the original version. The new ones have different data and, for some, a different structure, so do not just empty them. Remove them totally. Good luck! Change Log v1.1a: Current Version: Corrects a small error where an incorrect variable was used in the code to show the local time of the last update. If you already have v1.1, you only need to do the fix described in Post #82 below. v1.1: Changes display of last update time to be the correct time in the user's own local time zone; previously, it was always Eastern Time (GMT-5) (Upgrade instructions are in Post #79 below). Also breaks the weather_city.sql into six smaller pieces (useful only to new installations; existing installations need not worry about this). v1.0a: Adds instructions on how to add location to current weather on forums home page (changes to code added to index.php and forumhome_weather template). v1.0: Original Release Show Your Support
|
Comments |
#362
|
||||
|
||||
Will it work with weather in Scandinavia too?
|
#363
|
|||
|
|||
Hmm.
I got a wierd problem. most of the time it take realy long time for my index page to load. And when it does the weather is all messed up. No pic and the temperature is way off. I have to reload to make it work. Sometimes it takes around a minute to load. And i have to reload several times to make the weather work. Its a grate hack but the load times are annoying. /DonLKSAB |
#364
|
|||
|
|||
I'm having the exact same problem as the Don, terribly slow loading, if it loads at all... I've turned it off until I can figure out the malfunction .
|
#365
|
|||
|
|||
I have the same problem..at first I didn't know what it was...then narrowed it down to the weather hack server speed.
Had to take it out of index.php too because merely taking it our of the forumhome template wasn't good enough...shame too was a good hack for a while but not woth the headache with the slow load speeds |
#366
|
|||
|
|||
Question:
The code that is put into the index doesn't update the weather settings. You grab the weather from the server, display it, then it just goes away. It's not cached into the database. Why? Wouldn't it be more efficient if it grabs the weather, displays it, inserts/updates the weatherdata then exits? |
#367
|
|||
|
|||
I've seen teh same performance issues recently as well. COuldn't figure it out, as the pages would oad fine some of the time, then for no apparent reason, it'd take 50+ seconds of PHP processing for the page to load. Finally noticed that the pages that loaded slowly all showed no info for the weather.
Disabled the weather features and now the site sings again... Sad to see it go, but for a performance hit like that, I cannot justify the hack I did like it, though... as do many of my site's members. |
#368
|
|||
|
|||
just a note to you guys. I had a weather system installed on my board just liek this one..not sure if this is it. its a great informational tool, but DO NOT install it on the main forum home page....it stalls the loading of the forum..I lost half my visitors because of it....it took forever to load the main forum page because of that hack....make a link on the main forum page for it..but if its displayed live on the main forum page good luck trying to load your forum..its ridiculous...its sucks because I love the idea of this hack..
|
#369
|
|||
|
|||
I've been having excessively long load times to get to the main page of my forum, and it hadn't occurred to me to disable the weather hack and check. Through my installation of another hack today, I inadvertantly killed the weather display from my forum index. The page FLIES again. I won't be re-enabling the weather on my forum index any more. I'll just find somewhere to integrate it into my site, either via a link or button to "Your Weather" (http://yourdomain.com/yourforum/weather.php).
|
#370
|
|||
|
|||
Oh bugger! So that's why my vbhome portal was loading so slowly. Never occured it could be the weather.
Why is it suddenly doing this now? Never used to be a problem. Is there nothing can be done to pep it up again. I love this hack! *cry* |
#371
|
||||
|
||||
I've always had that problem with the hack, actually. Ever since I installed it, which was months ago... so what I did, was make it optional, where you could turn it on or off in the User CP. That way users stopped complaining about the slow loading time...
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|