Mike, Thanks for the quick reply. How much would you charge to implement this into my map? Feel free to contact me directly. Tom
On Jun 16, 2:51 pm, Mike Williams <[email protected]> wrote: > Since you've only got a few markers, you could do it all with Function > Closure, just like you do with the "html" for the info window. > > Get your phpsqlajax_genxml2.php to return the text for the DIV as > another marker attribute: > > <marker name="Pan Africa Market" > address="1521 1st Ave, Seattle, WA" > lat="47.608940" > lng="-122.340141" > weburl="http://www.imadesigner.co.uk" > type="restaurant" > txt="Some text to be placed in the side panel" /> > > Then read that new attribute in the same way that you read the existing > ones: > > var txt = markers[i].getAttribute("txt"); > > Pass that information to your createMarker() function, so that it can > obtain Function Closure on it, then pop the text into the side panel > when the marker is clicked: > > GEvent.addListener(marker, 'click', function() { > marker.openInfoWindowHtml(html); > document.getElementById("sidepanel").innerHTML = text; > }); > > If you feel that you really do need to know the index number of the > marker, then you'll need to obtain Function Closure on your "i" variable > by passing it to your createMarker() function. > > -- > Mike Williamshttp://econym.org.uk/gmap --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Google Maps API" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/Google-Maps-API?hl=en -~----------~----~----~----~------~----~------~--~---
