FREE Web Template Download
HTML CSS JAVASCRIPT SQL PHP BOOTSTRAP JQUERY ANGULARJS TUTORIALS REFERENCES EXAMPLES Blog
 

Maps API getCenter() Method

Map() Constructor Map() Constructor

Example

Return the latitude/longitude of the current center of the map:

map.getCenter();
Try it Yourself »

Definition and Usage

The getCenter() method returns the latitude/longitude of the current center of the map.


Syntax

mapvariable.getCenter();

Return Values

Value Description
latitude, longitude The latitude/longitude of the current center of the map

Map() Constructor Map() Constructor