Hey, You'll have to add the following wrapper before you load projections from spatialreference.org and before you load OpenLayers.js:
<script> window.Proj4js = { Proj: function(code) { return proj4(Proj4js.defs[code]); }, defs: proj4.defs, transform: proj4 }; </script> This is all. Andreas. On Thu, Oct 3, 2013 at 7:28 AM, Andrea Battisti <batti...@actgate.com>wrote: > Hello, > > Looks like that the latest version of Proj4js from: > https://github.com/proj4js/**proj4js <https://github.com/proj4js/proj4js> > > has a slightly different API then before, and indeed it does not seem to > work with the plain OL 2.13.1. > > Question: is there a patch available to use OL against the new Proj4js? > If not, which is the best way to make it compatible? > > As far as I see the code to adapt will be the OpenLayers.Projection class > in Projection.js; is that enough? are there other changes needed from the > OL perspective? > > > Thanks in advance! > -- > Ing. Andrea Battisti > ______________________________**_________________ > Dev mailing list > d...@lists.osgeo.org > http://lists.osgeo.org/**mailman/listinfo/openlayers-**dev<http://lists.osgeo.org/mailman/listinfo/openlayers-dev> >
_______________________________________________ Dev mailing list d...@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/openlayers-dev