Geolocation?
This topic contains 34 replies, has 7 voices, and was last updated by Vikas 9 years, 11 months ago.
We have moved to a support ticketing system and our forums are now closed.
Open Support Ticket-
AuthorPosts
-
April 23, 2014 at 11:53 am #660
Is geolocation available? I cannot find a way to enable it. A great feature that is essential if somebody is accessing it from their smartphone.
April 23, 2014 at 11:54 am #661HI,
We are working on it and it will be available shortly.
Thanks to be patient.
April 23, 2014 at 12:23 pm #665Thanks.
April 23, 2014 at 9:25 pm #691Awesome!
April 25, 2014 at 4:24 pm #806Hi justmark, at the moment, i include this plugin, and it works:
http://git.ladasoukup.cz/wp-google-map-with-routing-wp-pluginApril 25, 2014 at 4:25 pm #807Hi justmark, at the moment, i include this plugin, and it works:
http://git.ladasoukup.cz/wp-google-map-with-routing-wp-plugin
April 28, 2014 at 5:47 am #883Hi,
I will check too.
April 28, 2014 at 12:19 pm #910This is cool but in my opinion geolocation should be a core function and not a plugin but it definitely gets the job done!
April 29, 2014 at 9:56 am #966Strongly Agree
April 30, 2014 at 8:45 am #1037Hi Julian,
Thanks for sharing it. Would you mind sharing the steps on how to install and use it?
Once activating it, what short code do we use and where do we embed it? Is this all we have to do?
April 30, 2014 at 3:23 pm #1048Hi ManilaBoy, i make some modifications on the code of these plugin, not in geodirectory.
I make this:
1 install and activate the plugin.
2 on “edit place”, i put the code (modify for some adress near you for test) on the end of description area, when finish the description (see the screencaps)
3 look here the result:
http://sevilla.andeando.com/?gd_place=buddakanOn these, i’ve included the next code: [gmap-route addr=”Sant Pere, 12 Vila-seca, Spain” zoom=15 geo=”true” map_type=”ROADMAP” map_width=”600″ info_width=”600″ height=”400″ lang=”es”]
the perfection is if we can change the map on te “map section” for this, but i’m not very good programmer.
If you want the plugin modified by me, ask.
RegardsApril 30, 2014 at 4:03 pm #1056Hi, the problem with geolocation it’s not compatible with W3 Total Cache that is necessary for my site
April 30, 2014 at 4:47 pm #1060Thank you, Julian.
May 10, 2014 at 8:20 am #1650Hi
I don’t want to get too involved in offering support or solutions but if you want geolocation on search then you can do the following.
Add this code to the header – you can do that is geodirectory design options:
<?php global $goe_locate; if($goe_locate){echo $goe_locate;} ?> <script type="text/javascript"> function showLocation(position) { var latitude = position.coords.latitude; var longitude = position.coords.longitude; var add = latitude+','+longitude; document.getElementById('snear').value = add; } function errorHandler(err) { if(err.code == 1) { alert("Error: Access is denied!"); }else if( err.code == 2) { alert("Error: Position is unavailable!"); } } function getLocation(){ if(navigator.geolocation){ // timeout at 60000 milliseconds (60 seconds) var options = {timeout:60000}; navigator.geolocation.getCurrentPosition(showLocation, errorHandler, options); }else{ alert("Sorry, browser does not support geolocation!"); } } </script>
Then open up geodirectory-tempates > listing-filter-form.php and add at around line 46 just before the search button
<input type="button" class="geo" onclick="getLocation();" value="Find Me">
You can do basically the same with directions but the problem with directions is that the plugin currently uses the default location rather than the actual location.
You can see the geolocation hack at naturesites.co.uk
Kevin
May 10, 2014 at 8:42 am #1651Thank you for sharing it, Kevin.
Do you know how to automatically detect the user and load listings based on the user’s location instead of having him use the Find Me option?
-
AuthorPosts
We have moved to a support ticketing system and our forums are now closed.
Open Support Ticket