Open jrg96 opened 9 years ago
@royalharsh now that I think maybe could be convenient that in the start_conn.php script I send you the current lat/lng coords of the user, so in the start connection you can create the row of the specific user that is gonna be updated o,o , so you will have to modify the script:
any questions tell me o,o
@royalharsh I made som little changes to the backend of trackme, now I added to the start_conn.php and in the database the concept of room (the "virtual place" where you will be sharing your location information to others that are on the same room) so please:
Start the update_pos.php script, as GET params you will expect:
a) phone_id: the GUID I received previosly b) lat: new Latitude number c) lng: new Longitude number
So what you will be doing in update_pos.php is basically update my lat/lng coords and also the last_update field (with NOW(), you know that.....) please do that first task today and upload your work o,o
@GhostAlgorithm Added update_pos.php with update queries in trackme-backend
@royalharsh does the code work well? I mean, y see that in the WHERE clause you didn't typed ' ' surrounding the variable that's why I ask o,o (remember it's a string for the DB not a number)
@GhostAlgorithm Fixed...that was a typo :laughing: I tested the code and it worked! :astonished:
@GhostAlgorithm I think trackme doesn't work on cross browser while testing. I mean when I try sharing my location on a particular room using firefox and then I try sharing my location using IE on same room. I cannot find myself :scream: When I try in same browser, it works fine. It can track me.
@royalharsh
https://drive.google.com/file/d/0B1E5b7R8U4O7YW42anpRRnVUQTg/view
The way that IE gets user location coords seems wrong, I don't think there is a way to fix that because if the GPS coords obtained by the browser are wrong since the geolocation get user position, there's no way to fix that, as you see, it shows I'm in two different positions.
Maybe that's why you can't find yourself, if not, show a screenshot of the stracktrace in IE to see that an error is happening.
@GhostAlgorithm https://www.dropbox.com/s/332lsmsines8uct/fafa.png?dl=0 I tried it using firefox and IE, but its not able to get my location from firefox. It show different locations.
@royalharsh , basically that's no code problem, the problem is the way each browser deals with get user location, the same happens with me, but in different hours in the day, no matter what you change in the code, the problem is still with the browser and the way it gets the coords.
@GhostAlgorithm I think then we should assume that it would show the correct place on mobile phones.
@royalharsh made a little update, don't think this will fix the problem, but is the only thing we can do, it is supposed if you enable high acccuracy, at least in mobile devices, will use the GPS, the params explanation is here:
https://developer.mozilla.org/en-US/docs/Web/API/PositionOptions
Track Me!
Track location of your friends at real time!!