8/21/2016

Website : นำ Google map มาติดในหน้า Website

Website : นำ Google map มาติดในหน้า Website

วิธีทำ :
http://blog.readyplanet.com/15088455/%E ... google-map

ตัวอย่าง http://www.scivalve.com/contact.php

How to Embed Google Maps Responsively :
ใช้ code :
  1.    <style>
  2.         .google-maps {
  3.             position: relative;
  4.             padding-bottom: 75%; // This is the aspect ratio
  5.             height: 0;
  6.             overflow: hidden;
  7.         }
  8.         .google-maps iframe {
  9.             position: absolute;
  10.             top: 0;
  11.             left: 0;
  12.             width: 100% !important;
  13.             height: 100% !important;
  14.         }
  15.     </style>
  16.      
  17.     <div class="google-maps">
  18.         <iframe src="https://www.google.com/maps/embed?pb=!1m14!1m12!1m3!1d7098.94326104394!2d78.0430654485247!3d27.172909818538997!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!5e0!3m2!1sen!2s!4v1385710909804" width="600" height="450" frameborder="0" style="border:0"></iframe>
  19.     </div>


ที่มา http://www.labnol.org/internet/embed-re ... aps/28333/


ถ้าต้องการให้แผนที่ Zoom อีกให้ใส่

it seems you can use a
  1. &z=nn
parameter now Try this:

เช่น
  1. <iframe src="https://www.google.com/maps/d/u/0/embed?mid=zUAvuxyMmsZY.kshc6DxqAd0o&z=17.5" width="640" height="480"></iframe>


ที่มา http://gis.stackexchange.com/questions/ ... bedded-map

No comments:

Post a Comment