FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » Calculate the distance between 2 points
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: Calculate the distance between 2 points [message #171279 is a reply to message #171276] Thu, 30 December 2010 00:43 Go to previous messageGo to previous message
Sarah is currently offline  Sarah
Messages: 30
Registered: December 2010
Karma:
Member
I know this

$distanceValue =
rad2deg(acos(sin(deg2rad($LATITUDINE1))*sin(deg2rad($LATITUDINE2))
+cos(deg2rad($LATITUDINE1))*cos(deg2rad($LATITUDINE2))*cos(deg2rad($LONGITU DINE1-
$LONGITUDINE2))))*69.09;




or something like this.... but I don't want to have all records of DB
and than analize them one by one .... I want a query the return only
nearest values
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Checking equal number of <div> and </div>
Next Topic: extract variable from an array
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Wed Nov 27 02:48:49 GMT 2024

Total time taken to generate the page: 0.04852 seconds