[MetaCRS] Proj4js dynamic CRS lookup

Mike Adair madair at dmsolutions.ca
Mon Nov 1 13:48:13 EDT 2010


Jon,

Have a look at the file proj4js/test/runtests.js - in there you'll see a 
way to set a timer that checks the 'readyToUse' flag in a timer as one 
way to wait until the projection definition is ready.    You may also be 
able to modify the 'defsLoaded' function to call a user defined 
callback, that method is called by the onload handler for the script tag 
that loads the definition.

Mike



On 11/1/2010 1:34 PM, Jon Britton wrote:
> Hi,
>
> I'm trying to use proj4js in my project and will need to project to 
> various CRSs.  The projection codes are submitted by the user, so I 
> have no way of knowing what CRSs will be used.  I've looked at the 
> user guide and it says that proj4js can dynamically look up CRS info 
> at run-time, but I can't figure out how to set this up.  When I try 
> and carry out a projection, I just get the original values back...
>
> Any help would be appreciated,
>
> Jon
>
>
> _______________________________________________
> MetaCRS mailing list
> MetaCRS at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/metacrs

-- 
    Michael Adair
    Senior Software Architect
    DM Solutions Group Inc.

    Office: (613) 565-5056 x26
    madair at dmsolutions.ca
    http://www.dmsolutions.ca
    http://research.dmsolutions.ca


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/metacrs/attachments/20101101/6f931777/attachment.html


More information about the MetaCRS mailing list