Advertisement
Advertisement
| 09.24.2008 at 11:06AM PDT, ID: 23759710 |
|
[x]
Attachment Details
|
||
|
[x]
The Solution Rating System
|
||
With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.
Your Input Matters If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support. Thank you! |
||
1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19: 20: 21: 22: 23: 24: 25: 26: 27: 28: 29: 30: 31: 32: 33: 34: 35: 36: 37: 38: 39: 40: 41: 42: 43: 44: 45: 46: 47: 48: 49: 50: 51: 52: 53: 54: 55: 56: 57: 58: 59: 60: 61: 62: 63: 64: 65: 66: 67: 68: 69: 70: 71: 72: 73: 74: 75: 76: 77: 78: 79: 80: 81: 82: 83: 84: 85: 86: 87: 88: 89: 90: 91: 92: 93: 94: 95: 96: 97: 98: 99: 100: 101: 102: 103: 104: 105: 106: 107: 108: 109: 110: 111: 112: 113: 114: 115: 116: 117: 118: 119: 120: 121: 122: 123: 124: 125: 126: 127: 128: 129: 130: 131: 132: 133: 134: 135: 136: 137: 138: 139: 140: 141: 142: 143: 144: 145: 146: 147: 148: 149: 150: 151: 152: 153: 154: 155: 156: 157: 158: 159: 160: 161: 162: 163: 164: 165: 166: 167: 168: 169: 170: 171: 172: 173: 174: 175: 176: 177: 178: 179: 180: 181: |
'***START .aspx.vb *********************************************
Partial Class property_tax_comps_tracker_GoogleMapTester
Inherits BasePage
#Region " Declarations "
#End Region
#Region " Properties "
#End Region
#Region " Page Events "
Protected Sub Page_Init(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Init
Me.Title = ""
End Sub
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
If Not Me.IsPostBack Then
SetAttributes()
End If
End Sub
#End Region
#Region " Control Events "
#End Region
#Region " Methods "
Private Sub SetAttributes()
btnSearch.Attributes.Add("onclick", "showAddress('" & txtAddress1.ClientID & "','" & txtAddress2.ClientID & "','" & txtAddress3.ClientID & "'); return false;")
'btnSearch.Attributes.Add("onclick", "showAddress('100 Dundas St W, Toronto, ON, Canada'); return false;")
End Sub
#End Region
End Class
'***** END .aspx.vb *******************************************
'***** START .aspx ********************************************
<%@ Page Language="VB" MasterPageFile="~/Base/popup.master" AutoEventWireup="false" CodeFile="GoogleMapTester.aspx.vb" Inherits="property_tax_comps_tracker_GoogleMapTester" title="Untitled Page" %>
<asp:Content ID="Content1" ContentPlaceHolderID="cphCafe" Runat="Server">
<script src="http://maps.google.com/maps?file=api&v=2&key=ABQIAAAA3KaHauTINRDt9Mo_uXaKKxTmazC1CCL-aZvJBl4evHylXtqSchRXl_AMYsY059CcaNzFMcDNGSqDoQ" type="text/javascript" language="javascript">
</script>
<script type="text/javascript">
//<![CDATA[
var side_bar_html = "";
var gmarkers = [];
var i = 0;
//var map = new GMap2(document.getElementById("map"));
var geocoder = new GClientGeocoder();
function showAddress(addr1,addr2,addr3) {
//alert(addr)
var address1 = document.getElementById(addr1).value
var address2 = document.getElementById(addr2).value
var address3 = document.getElementById(addr3).value
//alert("Executing showAddress for " + address);
var map = new GMap2(document.getElementById("map"));
var bounds = new GLatLngBounds();
var sw = new GLatLng();
var ne = new GLatLng();
var rtn1 = false;
var rtn2 = false;
var rtn3 = false;
side_bar_html = '';
map.addControl(new GLargeMapControl());
map.addControl(new GMapTypeControl());
if (geocoder && GBrowserIsCompatible()) {
try{
//alert("Starting bounds = " + bounds);
map.setCenter(new GLatLng(0,0),12)
rtn1 = setMarkers(address1,0,map,bounds);
rtn2 = setMarkers(address2,1,map,bounds);
rtn3 = setMarkers(address3,2,map,bounds);
//alert("bounds, just before centering = " + bounds)
sw = bounds.getSouthWest();
ne = bounds.getNorthEast();
map.setMapType(G_HYBRID_MAP);
//****NOTE: the setCenter & setZoom only work if the following alert is allowed to run! *******************
alert("Zoom before setting = " + map.getBoundsZoomLevel(bounds));
if (rtn1 == true && rtn2 == true && rtn3 == true){
map.setCenter(bounds.getCenter());
map.panTo(bounds.getCenter());
map.setZoom(map.getBoundsZoomLevel(bounds));
}
}catch(Error){
}
}else{
alert("Geocoder not here or Google Maps API is not compatible with this browser!");
}
}
function setMarkers(address,j,map,bounds){
try{
geocoder.getLatLng(
address,
function(point) {
if (!point) {
alert(address + " not found");
} else {
var marker = new GMarker(point);
GEvent.addListener(marker, "click", function() {
marker.openInfoWindowHtml(address);});
map.addOverlay(marker);
gmarkers[j] = marker
var lat = point.y;
var lng = point.x;
var spot = new GLatLng(lat,lng)
bounds.extend(spot)
//alert("Bounds = " + bounds + " j = " + j)
side_bar_html += '<a href="javascript:myclick(' + j + ')">' + address + '</a><br>';
//alert("Adding marker for " + address + " , side_bar_html= " + side_bar_html + " , j = " + j );
document.getElementById("side_bar").innerHTML = side_bar_html;
marker.openInfoWindowHtml(address);
}
}
);
return true;
}catch(e){
alert(e.message);
return false;
}
}
function myclick(i){
GEvent.trigger(gmarkers[i],"click");
}
//]]>
</script>
<body onunload="GUnload()">
<table>
<tr>
<td>
<div id="map" style="width: 800px; height: 600px"></div>
</td>
<td width="400" valign="top" style="text-decoration:underline; color:Blue;">
<div id="side_bar"></div>
</td>
</tr>
</table>
<table width="100%">
<tr>
<td align="right">
Add new address markers here:
</td>
<td class="l_box_item">
<asp:textbox id="txtAddress1" MaxLength="500" Width="600" runat="server"></asp:textbox>
<asp:button ID="btnSearch" runat="server" Text="Search" />
</td>
</tr>
<tr>
<td>
</td>
<td class="l_box_item">
<asp:TextBox ID="txtAddress2" MaxLength="500" Width="600" runat="server"></asp:TextBox>
</td>
</tr>
<tr>
<td>
</td>
<td class="l_box_item">
<asp:TextBox ID="txtAddress3" MaxLength="500" Width="600" runat="server"></asp:TextBox>
</td>
</tr>
</table>
</body>
</asp:Content>
|