Add user geolocation to your JobRoller site!
Save users from needing to manually enter their location and, as the plugin uses the same Google Geocoding service as JobRoller, all dynamically generated locations will be recognised as valid addresses for location searches.
The User Locator plugin adds the following user geolocation functionality to JobRoller:
‘Location’ field is added to the user – this can be edited on the JobRoller edit profile page or from the WordPress user profile panel.
On each page load the following happens:
If a user has specified their location in their profile it is used to populate the ‘Location’ search box.
If the user is not logged in or has not set their location, then the users location (latitude and longitude coordinates) is grabbed using html5 geolocation.
Their location is then reverse geocoded to attempt to get a human readable address. You can now select the component/format of the output address. Choose to display the the full address, town, postal code etc. If this is successful the address is displayed in the ‘Location’ box. If geocoding fails to get a human readable address the lat,lng coordinates are placed in the ‘Location’ box so the search results will still be relevant to their current location.
If at any time the ‘Location’ box is already populated from a current search this is respected and nothing is changed.
A small link is also inserted next to the search radius option. Clicking on this link at any time will initiate geolocation and update the ‘Location’ box accordingly.