Version: 1.00, by WreckRman2
Developer Last Online: Jul 2014
Version: 3.0.0
Rating:
Released: 03-29-2004
Last Update: Never
Installs: 10
No support by the author.
This is very, very simple addon done in less than 30 minutes. It can be made much better but it's a start. If someone else want to modify it and make it better please feel free to do so!
Step 1: Open your ACP and select "Add New User Profile Field", choose single line text box. Create new field titled "Zip Code".
Step 2: Open "User Profile Field Manager" and look for the Zip Code field number. In my instance it was field 10.
Step 3: Open your "index" template and place the following code where you want the weather conditions box to appear.
Code:
<!-- Weather Block -->
<table align="center" border="0" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" class="tborder" width="100%">
<tr>
<td class="tcat"><span class="smallfont"><b>$vboptions[blockbullet] Weather Conditions</b></span></td>
</tr>
<tr>
<td class="$getbgrow"><span class="smallfont">
<if condition="!$bbuserinfo['userid']">
<span class="smallfont">$vbphrase[a_not_a_member_yet]<br /><a href="$vboptions[bburl]/register.php">$vbphrase[a_register_now]</a> to show weather conditions.</span>
<else />
<if condition="$bbuserinfo[field10] !=''">
<a href="http://www.weatherroom.com/forecast/$bbuserinfo[field10].html"><img src="http://www.weatherroom.com/weather?forecast=zone&hwvtc=black&hwvbg=E1E4F2&pands=$bbuserinfo[field10]&config=png&alt=hwivzone&daysonly=1" alt="Weather for $bbuserinfo[field10] provided by weatherroom.com." border="0"></a>
<else />
<A HREF="$vboptions[bburl]/profile.php?do=editprofile">Add Zip Code</A> to show weather conditions.
</if>
</if>
</span>
</td>
</tr>
</table>
<br/>
<!-- End Weather Block -->
Step 4: IMPORTANT! Change all instances of $bbuserinfo[field10] to whatever your field number is. If it is number 13 change it to $bbuserinfo[field13]. If you forget this step it will not work!
Step 5: Save the changes and enjoy!
If your visitor isn't a member it tells them they must register to show the weather. If they are a member but haven't filled in the Zip Code field it tells the user they must edit their profile to add a zip code. If they have a zip code in their profile it will show a 5 day forecast of the weather in their area.
I like this, but it says my zip isn't found . . . I live in a county with over $1m people . . .
The location you selected to search for was not found.
HAMweather 3 by default, normally can display the information for locatons with in the US that have zipcodes, and international locations which have an valid internationally reporting ICAO station.
If you entered in a location of a small town of location, it may be that this location is not in the current HAMweather 3 database. If you continue to have trouble with this location you may email the name of the location and what major city or county it is close to to the HAmweather administrator at hw3admin@hamweather.com for possible future addition to the HAMweather database.