![]() |
|
Mod Options |
![]() |
|||||||||
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/...r-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 Now Only licensed members can download files, Click Here for more information. Show Your Support
No members have liked this post.
|
![]() |
||||
Mod | Developer | Type | Replies | Last Post |
vB Weather: Give your members current weather and forecasts! | JJR512 | vBulletin 2.x Full Releases | 143 | 15 Aug 2002 21:12 |
Comments |
#2
|
||||
|
||||
any screen shot?
No members have liked this post.
|
#3
|
|||
|
|||
Thanks for reminding me, just added it!
__________________
http://www.maineforums.net No members have liked this post.
|
#4
|
||||
|
||||
nice idea and i did exactly what you wrote but nothing is showing.my field # is ok too.any idea
ok i got it for some reason when i put this <if condition="$post['fieldXX']"> in the begining then it doesn't show,when i remove this then its ok? No members have liked this post.
Last edited by apiasto; 27 Sep 2009 at 15:04. |
#5
|
|||
|
|||
I see what I did, change
<if condition="$post['fieldXX']"> to <if condition="$bbuserinfo['fieldXX']"> Updated original code.
__________________
http://www.maineforums.net No members have liked this post.
|
#6
|
||||
|
||||
all right kool its working now thnx. one thing i wanna ask how about like if i wanna put a place from asia where zip code is not common.in otherwords when i try to put just city name it shows error saying invalid location code.is there a way to over come that so user can just put their city name to get weather.thnx
No members have liked this post.
|
#7
|
||||
|
||||
all right kool its working now thnx. one thing i wanna ask how about like if i wanna put a place from asia where zip code is not common.in otherwords when i try to put just city name it shows error saying invalid location code.is there a way to over come that so user can just put their city name to get weather.thnx
No members have liked this post.
|
#8
|
|||
|
|||
Not working for me either.
No members have liked this post.
|
#9
|
|||
|
|||
You would need to go to weather.com and put in your location. The link will show something like this..
http://www.weather.com/outlook/trave...raveler/local/FRXX0076?lswe=Europe&from=searchbox_localwx They would enter the code right before the question mark, the part in red.
__________________
http://www.maineforums.net No members have liked this post.
|
#10
|
|||
|
|||
What isn't working?
__________________
http://www.maineforums.net No members have liked this post.
|
#11
|
|||
|
|||
Can you be more specific on exactly what you need to put in the profile fields?
No members have liked this post.
|
#12
|
|||
|
|||
this is what I have
<if condition="$bbuserinfo['field36']"> <script type="text/javascript" src="http://voap.weather.com/weather/oap/$bbuserinfo[field36] ?template=GENXH&par=3000000007&unit=0&key=twciweatherwidget"></script></div></if> No members have liked this post.
|
#13
|
||||
|
||||
all you gotta do is put pfofile field id # which you will get after creating one
No members have liked this post.
|
#14
|
|||
|
|||
Done that and it's not showing.
No members have liked this post.
|
#15
|
||||
|
||||
Originally Posted by BigDog56
it looks ok ,i guess now you have to make entry in the field by going to your cp panel and putting your zip code.it should be available where you saved it in profile field catagory like edit your details![]()
mine is working here No members have liked this post.
|
![]() |
«
Previous Mod
|
Next Mod
»
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Mod Options | |
|
|
New To Site? | Need Help? |
All times are GMT. The time now is 03:04.