Question from non-developer

35 views
Skip to first unread message

Tal Shuv

unread,
Oct 24, 2011, 4:21:26 PM10/24/11
to google-map...@googlegroups.com
Hello, if anyone can help, I would really appreciate it.

I'm trying to customize the colors of the map my WP plugin uses.

function init_basic_map(lat,lng,marker_text) {
store_wpress_map = new google.maps.Map(document.getElementById("map"), {
center: new google.maps.LatLng(lat, lng),
zoom: Store_wpress.zoom_detail,
mapTypeId: Store_wpress.map_type,
mapTypeControlOptions: {style: google.maps.MapTypeControlStyle.DEFAULT}
});

I know I'm supposed to use MapTypeStyler but don't know where to put it... or how to use it...

I want to use these colors:
[ { stylers: [ { visibility: "simplified" }, { hue: "#00eeff" }, { lightness: 13 }, { saturation: -58 }, { gamma: 0.81 } ] } ]

Any ideas?
Thanks!

Radina

unread,
Oct 24, 2011, 7:28:19 PM10/24/11
to Google Maps JavaScript API v3
var myOptions =
{
zoom: 9,
center: myCenter,
mapTypeControl: false,
mapTypeId: G.MapTypeId.ROADMAP,
useStaticMap: false,
streetViewControl: false,
styles: [
{ stylers: [ { visibility: "simplified" }, { hue:
"#00eeff" }, {
lightness: 13 }, { saturation: -58 }, { gamma: 0.81 } ] }

]
}
map = new G.Map(document.getElementById("map_canvas"), myOptions);


For more options:

http://code.google.com/apis/maps/documentation/javascript/styling.html
Reply all
Reply to author
Forward
0 new messages