Support

Account

Home Forums Front-end Issues Assemble Google Map location based on address fields Reply To: Assemble Google Map location based on address fields

  • I have some examples of adding custom JS to update fields based on other fields, but not anything for your exact needs. Getting the value from a text field should be fairly easy.

    When targeting fields you need to use something like

    
    $('[data-key="field_0123456789"] input')
    

    for a text field, field names are not used in the input fields when editing, only the keys. The name of the field is in a data attribute, but it’s always easier to use field keys.

    Updating the google maps field, I have not done this yet. I would start by figuring out what field in the map field needs to be updated and then I’d look for the action to trigger the map field to do it’s thing. This could be as simple as triggering a change event on the input field where you insert the value.