jQueryMobile with Google Map

09 Sep
jQueryMobile with Google Map

jQueryMobile with Google Map


This demo is based on jQuery UI plugin for Google Maps.

<!doctype html>
<html lang="en">
<title>jQuery mobile with Google maps</title>
<link rel="stylesheet" href="" />
<script src=""></script>
<script src=""></script>
<script type="text/javascript" src=""> </script>
<script type="text/javascript" src=""></script>
<script type="text/javascript">

var colombo = new google.maps.LatLng(26.5727,73.8390);
var delhi = new google.maps.LatLng(28.6100,77.2300);
mobileDemo = { 'center': '28.6100,77.2300', 'zoom': 12 };

function initialize() {
$('#map_canvas').gmap({ 'center':, 'zoom': mobileDemo.zoom, 'disableDefaultUI':false });
$('#map_canvas').gmap('addMarker', { 'position': delhi } );

$(document).on("pageinit", "#basic-map", function() {

$(document).on('click', '.add-markers', function(e) {
$('#map_canvas').gmap('addMarker', { 'position': colombo } );
<div id="basic-map" data-role="page">
<div data-role="header">
<h1><a data-ajax="false" href="#">jQuery mobile with Google</a></h1>
<a data-rel="back">Back</a>
<div data-role="content">
<div style="padding:1em;">
<div id="map_canvas" style="height:350px;"></div>
<a href="#" data-role="button" data-theme="b">Add Some More Markers</a>
1 Comment

Posted by on September 9, 2013 in jQueryMobile



One response to “jQueryMobile with Google Map

  1. Wanjohi Kibui

    January 23, 2015 at 4:46 am

    Hello,Am glad that I found this site today.Am a GIS student developing in Javascript(Extjs+GeoExt+PostGIS+Geoserver) and would really like to do good in this sector.Am a beginner and as always getting some barries but hope to tackle them all in future.Nice work you have here.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: