Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

143
Views
Google Maps API V3 - KML Layer and draw polygon

Thank you in advance for reading my problem.

I am currently creating a google maps and loading a klm file into it with geoXML3.

    <script type="text/javascript">
    $(function(){
         // create map
         var singapoerCenter=new google.maps.LatLng(45.677181, 14.119160);
 
         var myOptions = {
            zoom: 12,
            center: singapoerCenter,
            mapTypeId: google.maps.MapTypeId.ROADMAP
         }
          
         map = new google.maps.Map(document.getElementById('main-map'), myOptions);
         
          var myParser = new geoXML3.parser({
          map: map,
          singleInfoWindow: false
         });
        
         myParser.parse('./datafile.kml');                           
                     
    });
    </script>
 <div id="main-map" style="height: 400px;"></div>

that works fine so far. How can I now freely draw a new polygon on this existing layer?

thank you for your help!

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!