Project Detail

Google Map query window tweaks  

Google Map query window tweaks is project number 382939
posted at Freelancer.com. Click here to post your own project.

 

| More Free Trial For New Buyers
 

Status:

Selected Providers: outsourcedev

Budget: $30-250

Created: 02/09/2009 at 23:34 EST

Bid Count: 9

Average Bid:
N/A

02/16/2009 at 23:34 EST

Project Creator: eladnitram
Employer Rating: (No Feedback Yet)

Bid On This Project
 

Description

This is a project similar to one which had many responses.

I have a MySQL table that writes to an XML file, which then outputs markers to a google map. When you click on a marker, it contains certain field outputs from the table (simple example based on google bar/restaurant type tutorial).

The MySQL database (which table writes to the XML file) executes PHP based web pages to produce various search and record-detail output pages which also contains the longitude and latitude points which plot the markers.

This project entails completing the following, based on what has been accomplished already.

1) The info window should have a link corresponding to the query output detail PHP page (url) for that record.

2) The info window font style and size should match the corresponding query detail page.

3) The XML code and google code on htm pages should be optimized to keep the scripting and outputs as efficient as possible.

For more detail, see below:
I have created a MySQL database which outputs PHP pages for a client's sites. I created PHP search and record detail web pages using DBQwiksite. There are three test locations with correct latitude and longitude coordinates in corresponding fields. Using the documentation at Google I have managed to have the MySQL table write to XML to plot marker points on the googlemap and the info window displays assigned variables from the database fields:

(relevant part of code which does this)

GDownloadUrl("genxml3.php", function(data) {
var xml = GXml.parse(data);
var APS = xml.documentElement.getElementsByTagName("marker");
for (var i = 0; i < APS.length; i++) {
var Board_ID = APS[i].getAttribute("Board_ID");
var Street_Address = APS[i].getAttribute("Street_Address");
var City = APS[i].getAttribute("City");
var point = new GLatLng(parseFloat(APS[i].getAttribute("Latitude")),
parseFloat(APS[i].getAttribute("Longitude")));
var marker = createMarker(point, Board_ID, Street_Address, City);
map.addOverlay(marker);
}
});
}
}

function createMarker(point, Board_ID, Street_Address, City) {
var marker = new GMarker(point, customIcons[Board_ID]);
var html = "<b>" + Board_ID + "</b> <br/>" + Street_Address + "<br/>" + City;
GEvent.addListener(marker, 'click', function() {
marker.openInfoWindowHtml(html);
});
return marker;
}
//]]>
</script>
</head>

<body onload="load()" onunload="GUnload()">
<div id="map" style="width: 772px; height: 584px"></div>
</body>
</html>

The map that renders this is here: http://insitemediacom.net/boards/gmap2.htm

(this map is centered on one of the test markers in Tallahassee, Florida)

The PHP page that relates to the marker on this map is here: http://insitemediacom.net/boards/insite_more.php?search_fd0=4
You will notice that the field output for "Board_ID", "Street_Address" and "City" are the same as in the info window from the gmap2.htm marker in Tallahassee--this shows that the info window text is derived from the database table.

What I am trying to do is to make the Board_ID display in the info window hyperlink to the PHP page:

http://insitemediacom.net/boards/insite_more.php?search_fd0=4

The primary key on this database is simply called "Key" and the number "4" is the unique Key identifier for this record. I realize that I will need to introduce the "Key" variable in the XML file and the code above but what has me stumped is the co-mingling of html hyperlink tags with google code to link to the corresponding PHP page.
There may be a better approach...

Messages Posted:0 View project clarification board Post message on project clarification board

Bid On This Project
 

If you are the project creator or one of the bidders Log In for more options

Bids are hidden by the project creator. Log in as the project creator or as one of the bidders to view bids. You will not be able to bid on this project if you are not qualified in one of the job categories. To see your qualifications click here.


    Bid on this Project