I am using custom tile overlays on a map. To fetch the tiles I use the generic method:
function createImageMapType(id, opacityvalue) { return new google.maps.ImageMapType({ getTileUrl: function(coord, zoom) { return "/tiles/" + id + "/"+ zoom + "_" + coord.x + "_" + coord.y + ".png"; }, tileSize: new google.maps.Size(256, 256), isPng: true, opacity: opacityvalue }); } Here is the problem: My map uses lots of transparent PNG tiles, and infact some tiles are completely transparent. So rather than have thousands of 3kb empty PNG files, I just don’t have those tiles. This works but it technically generates a lot of 404 bad request errors. An average user visit can make as many as 300 bad requests. This really hurts page load time and also looks bad for search engines. So, does anyone have an idea how I could only fetch tiles that actually exist? One other idea I have had is could I setup an .htaccess rule that redirects to a universal empty PNG file for any tile that can’t be found (so it doesn’t return a bad request). I don’t want to generate empty tiles as I have over 130 custom tile overlays for zoom levels 1 through 5. Just at zoom level 5 that would be something like 140,000 files and my server is limited. -- 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.