Skip to content

Commit f2c9478

Browse files
committed
improve docs and remove debug code
1 parent 7261119 commit f2c9478

File tree

2 files changed

+8
-5
lines changed

2 files changed

+8
-5
lines changed

jgeo/assets/js/jgeo.js

+3-5
Original file line numberDiff line numberDiff line change
@@ -30,18 +30,16 @@ var JGeo = {
3030
},
3131

3232
fallback: function() {
33-
console.log('fallback');
33+
// if all else fails and things go horribly wrong
34+
// we can do something here
3435
},
3536

3637
success_callback: function(p) {
37-
console.log(p);
3838
JGeo.registerSessionLocation(p.coords.latitude, p.coords.longitude);
39-
40-
console.log();
4139
},
4240

4341
error_callback: function(p) {
44-
console.log(p);
42+
// Eventually add some final fallback options
4543
},
4644

4745
/*

readme.md

+5
Original file line numberDiff line numberDiff line change
@@ -18,5 +18,10 @@ if ($session->get('jgeo_position_status', false)) {
1818
// the object will be an empty array if it hasn't been set as well
1919
$position = json_decode($session->get('jgeo_position'));
2020
var_dump($position);
21+
22+
// access the object data
23+
$lat = $location->latitude;
24+
$lng = $location->longitude;
2125
}
26+
2227
```

0 commit comments

Comments
 (0)