Quote:
Originally posted by Julio
PlurPlanet - Can you please shoe me how to set it up that I can turn it on/off from the CP?
|
Sure, it's not very hard to do.
Just open the file the weather is displayed on (I'd assume it would be your forums/index.php, but of course you can display it in any file) and add this code right before the code for the weather:
PHP Code:
if ($showweather) {
Then right after the code for the weather add a } to close out that if statement.
Then using phpMyAdmin run this query:
PHP Code:
INSERT INTO setting VALUES (NULL,1,'Show Weather?','showweather','0','Show the weather forcast on your homepage.','yesno','3');
That will display the option right below the "Reason for turning board off" option in your Admin CP. If you know anything about the "setting" table you can change those values in the query to display it somewhere else. If you don't know how to change the setting and want it displayed somewhere else just PM me and let me know where you want it and I'll give you the code.