Sunday, 12 July 2015

coordinate system - How do I include proj4js in openlayers?


In my Openlayers app, since the base map projection is not epsg900913 or 4326, I need to include proj4js in order to use geolocation feature. but I got such an error notice:


 GET http://svn.osgeo.org/metacrs/proj4js/trunk/lib/projCode/null.js 404 (Not Found)

I am wondering how come this null.js is needed here. the funny thing is I can't find this file from proj4js lib files..


anybody can help me out?



Code:


 















Answer



After looking at your code it seems the error is in the definition of EPSG26912 where a colon is missing. Try the changes on local copy and then report them to the developers. You should never link to code from SVN trunk, anyway because of both performance and stability issues. Instead use a stable version of proj4js or a local checkout.


No comments:

Post a Comment

arcpy - Changing output name when exporting data driven pages to JPG?

Is there a way to save the output JPG, changing the output file name to the page name, instead of page number? I mean changing the script fo...