181
rated 0 times
[
184]
[
3]
/ answers: 1 / hits: 29165
/ 15 Years ago, fri, june 19, 2009, 12:00:00
I have the Lat/Long value of New York City, NY; 40.7560540,-73.9869510 and a flat image of the earth, 1000px × 446px.
I would like to be able to convert, using Javascript, the Lat/Long to an X,Y coordinate where the point would reflect the location.
So the X,Y coordinate form the Top-Left corner of the image would be; 289, 111
Things to note:
- don't worry about issues of what projection to use, make your own
assumption or go with what you know
might work - X,Y can be form any corner of the image
- Bonus points for
the same solution in PHP (but I
really need the JS)
More From » php