Can you post a link to an online version of your code - there's no way to debug a code dump.
Martin. On Nov 9, 7:47 am, Map Guy <rclair...@gmail.com> wrote: > Thank you for your reply. Good catch. > > I added "tileSize: new google.maps.Size(256, 256)," > > But I still seem to be running into the same issue. Any ideas? > > Complete text: > > <!DOCTYPE html> > <html> > <head> > <title>Google Maps JavaScript API v3 Example: Styled MapTypes</title> > <link href="http://code.google.com/apis/maps/documentation/javascript/ > examples/default.css" rel="stylesheet" type="text/css" /> > <script type="text/javascript" src="//maps.googleapis.com/maps/api/js? > sensor=false"></script> > <script> > > var map; > var brooklyn = new google.maps.LatLng(40.6743890, -73.9455); > > var MY_MAPTYPE_ID = 'hiphop'; > > function initialize() { > > var stylez = [ > { > featureType: "road", > elementType: "geometry", > stylers: [ > { hue: -45 }, > { saturation: 100 } > ] > }, > { > featureType: "landscape", > elementType: "geometry", > stylers: [ > { hue: "#000000" }, > { saturation: 75 }, > { lightness: -100} > ] > } > ]; > > var mapOptions = { > zoom: 12, > center: brooklyn, > mapTypeControlOptions: { > mapTypeIds: [google.maps.MapTypeId.ROADMAP, MY_MAPTYPE_ID] > }, > mapTypeId: MY_MAPTYPE_ID > }; > > map = new google.maps.Map(document.getElementById("map_canvas"), > mapOptions); > > var styledMapOptions = { > getTileUrl: function(coord, zoom) > { > return "http://foo.com/foo.png"; > }, > tileSize: new google.maps.Size(256, 256), > name: "Hip-Hop" > }; > > var jayzMapType = new google.maps.ImageMapType(styledMapOptions); > > map.mapTypes.set(MY_MAPTYPE_ID, jayzMapType);} > > </script> > </head> > <body onload="initialize()"> > <div id="map_canvas" style="width: 640px; height: 480px;"></div> > </body> > </html> > > On Nov 8, 11:36 pm, Martin™ <warwo...@gmail.com> wrote: > > > > > > > > > Hi. > > >http://code.google.com/apis/maps/documentation/javascript/maptypes.ht... > > > Looks like you've not defined a (required) 'tileSize' property in your > > options. > > > Martin. > > > On Nov 9, 6:20 am, Map Guy <rclair...@gmail.com> wrote: > > > > Starting with this example: > > > >http://code.google.com/apis/maps/documentation/javascript/examples/ma... > > > > Changing: > > > > var jayzMapType = new google.maps.StyledMapType(stylez, styledMapOptions); > > > > To > > > > var jayzMapType = new google.maps.ImageMapType(styledMapOptions); > > > > Where: (getTileUrl is the addition) > > > > var styledMapOptions = { > > > getTileUrl: function(coord, zoom) > > > { > > > return "http://foo.com/foo.png"; > > > }, > > > name: "Hip-Hop" > > > }; > > > > Results in (IE): > > > > Message: Expected value implementing google.maps.MapType > > > Line: 1 > > > Char: 28 > > > Code: 0 > > > URI:http://maps.gstatic.com/intl/en_us/mapfiles/api-3/7/0/main.js > > > Is there something basic I'm missing here or is this a bug? > > > > Thanks- Hide quoted text - > > > - Show quoted text - -- You received this message because you are subscribed to the Google Groups "Google Maps JavaScript API v3" group. To post to this group, send email to google-maps-js-api-v3@googlegroups.com. To unsubscribe from this group, send email to google-maps-js-api-v3+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-maps-js-api-v3?hl=en.