Support » Plugin: Google Map for Contact Form 7 » Is it possible to automatically locate the user’s current

  • My query is how can I make the user’s current location automatically on the map of the form, so that from that point the user can have the facility to move the marker more quickly and simply

Viewing 1 replies (of 1 total)
  • Plugin Author Aurovrata Venet


    You will need to interact with the gmp3 object.

    If you are using the CF7 Smart Grid UI editor plugin, you will get in-line helper codes as this plugin now integrates with the UI editor, simply copy the js helper codes to your js file (see screenshot #17 on the smart grid plugin page). Else, you can see FAQ #10 oof this plugin page to for an example js code.

    You will need the helper js code which binds to the initialisation of the gmap3 object. You can then add a marker to the map (remember to reset the centre as well) with the value of the current user location.

    You will likely need to set the current marker to null on the map so as not to end up with 2 markers,

     marker = null;

    the marker object is passed in the je event.

Viewing 1 replies (of 1 total)
  • The topic ‘Is it possible to automatically locate the user’s current’ is closed to new replies.