File tree Expand file tree Collapse file tree 3 files changed +9
-3
lines changed Expand file tree Collapse file tree 3 files changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -125,6 +125,8 @@ if __name__ == "__main__":
125125- ** style** : A string containing CSS styles. Defaults to ` "height:300px;width:300px;margin:0;" ` .
126126- ** identifier** : The CSS ID selector name.
127127- ** cls** : The CSS Class selector name. Defaults to ` "map" ` .
128+ - ** language** : The map language. Defaults to ` "en" ` .
129+ - ** region** : The map region. Defaults to ` "US" ` .
128130
129131Also controls True or False:
130132
Original file line number Diff line number Diff line change @@ -19,6 +19,8 @@ def __init__(self,
1919 varname = 'map' ,
2020 style = "height:300px;width:300px;margin:0;" ,
2121 cls = "map" ,
22+ language = "en" ,
23+ region = "US" ,
2224 rectangles = None ,
2325 circles = None ,
2426 polylines = None ,
@@ -38,6 +40,8 @@ def __init__(self,
3840 """Builds the Map properties"""
3941 self .cls = cls
4042 self .style = style
43+ self .language = language
44+ self .region = region
4145 self .varname = varname
4246 self .center = (lat , lng )
4347 self .zoom = zoom
@@ -710,7 +714,7 @@ def as_json(self):
710714 'zoom_control' : self .zoom_control ,
711715 'maptype_control' : self .maptype_control ,
712716 'scale_control' : self .scale_control ,
713- 'streetview_controle ' : self .streetview_control ,
717+ 'streetview_control ' : self .streetview_control ,
714718 'rotate_control' : self .rotate_control ,
715719 'fullscreen_control' : self .fullscreen_control ,
716720 'cluster' : self .cluster ,
Original file line number Diff line number Diff line change 11
22{% if not is_googlemaps_loaded() %}
33 {% if GOOGLEMAPS_KEY %}
4- < script src ="//maps.googleapis.com/maps/api/js?key={{GOOGLEMAPS_KEY}} " type ="text/javascript "> </ script >
4+ < script src ="//maps.googleapis.com/maps/api/js?key={{GOOGLEMAPS_KEY}}&language={{gmap.language}}®ion={{gmap.region}} " type ="text/javascript "> </ script >
55 {% else %}
6- < script src ="//maps.googleapis.com/maps/api/js " type ="text/javascript "> </ script >
6+ < script src ="//maps.googleapis.com/maps/api/js?language={{gmap.language}}®ion={{gmap.region}} " type ="text/javascript "> </ script >
77 {% endif %}
88 {{ set_googlemaps_loaded() }}
99{% endif %}
You can’t perform that action at this time.
0 commit comments