Hello!

I'm using a php variable that reads the url from a mysql database,
wich contains the url for the KML file i want to overlay the map, but
there is some problem with this, beacause no overlay appears. If I
give the PHP variable a static url (the same url wich i get by alert
(url)), everything works well. Both parts are in the same php file and
the alert(url) returns me the correct url to the kml file. But the
overlay doesn't work with it. In the following the code

--> THE PHP PART

$file_name = $row['wir_upload_kml_file'];
$file_url = SITEURLBASE.e_PLUGIN_ABS."wir/uploads/kml/".$file_name;

--> THIS IS THE JAVASCRIPT CODE

  var map;
  var gxml;

  function initialize() {

    map = new google.maps.Map2(document.getElementById('map'));
    var url = '$file_url';
    gxml = new GGeoXml(url);
    map.addControl(new GLargeMapControl());
    map.setCenter(new google.maps.LatLng(0,0),2.0);
    map.addControl(new GMapTypeControl());
    alert(url);
    map.addOverlay(gxml);

I'm sorry that I can'T post a url to the page, beacause its running on
localhost

--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to