[OpenLayers-Users] Projection issues

Christopher Schmidt crschmidt at metacarta.com
Sun Dec 28 18:35:46 EST 2008


On Mon, Dec 29, 2008 at 12:17:10PM +1300, Neil Fincham wrote:
> Hi All,
> 
> I feel as if I have been hit particularly hard with the stupid stick this
> morning ;) .
> 
> I need to make a map in epsg:2193 (NZGD2000 / New Zealand Transverse
> Mercator 2000) so I made a quick map file with a simple grid on it for
> testing purposes ( http://dev.asdf.co.nz/Grid.map ) and then test it through
> the CGI
> (http://dev.asdf.co.nz/cgi-bin/mapserv?map=/var/www/html/dev.asdf.co.nz/web/
> Grid.map&mode=map ).  All working so far.
> 
> Next I through together a simple OpenLayers app to get my grid up and then
> start adding layers, that can be found here ( http://dev.asdf.co.nz/  ) but
> my grid has disappeared!  To make things stranger I turn off all the options
> (Basically a restrictExtent) and the map is still blank BUT if you click
> into in for a bit you will find lots of "globes" floating around down there.
> 
> It basically comes down to my lack of knowledge about projections etc but
> can someone point me in the right direction.

try these for your mapOptions:

Map("map", {
  maxExtent: extent, // as already defined
  maxResolution: 'auto'
});  

You don't need the restrictedExtent in that case.

Regards,
-- 
Christopher Schmidt
MetaCarta



More information about the Users mailing list