|
Display Member Weather
This is the first time I have done anything like this but it will allow you to display your members local weather using weather.com.
First you need to create a new profile field that is a single-line text box called Zip Code. It can remain a private or public field, whatever you would like. Make note of the field number. Then, go to http://www.weather.com/services/oap/weather-widgets.html and choose from the two variations and put in just anything for a location, then select get code. You will be given something like this: <script type="text/javascript" src="http://voap.weather.com/weather/oap/04758?template=GENXV&par=3000000007&unit=0&key=twciweatherwidget"></script></div> You need to replace the zip code with this, $bbuserinfo[fieldXX] Make sure to change the XX to the field number. Then go into your templates and place the following code anywhere you want the weather to be displayed. <if condition="$bbuserinfo['fieldXX']"> <script type="text/javascript" src="http://voap.weather.com/weather/oap/$bbuserinfo[fieldXX]?template=GENXV&par=3000000007&unit=0&key=twciweatherwidget"></script></div></if> Again, don't forget to change both of the red parts to match the field number. Hope people find this of use, be kind as this is the first time I've done this ![]() Here is a screenshot! ![]() Download No files for download. |
|||||||||
Similar Mods
| vB Weather: Give your members current weather and forecasts! | vBulletin 2.x Full Releases |