Thanks again for your interest John!
Actually, I found my way through this problem and sharing here, in case it helps anyone.
Since I wanted this map to be set globally from the header, then it would require the
acf_form_head() to be always loaded.
It took some effort, but I ended up with this solution:
– Created a separate page
– Added the google map form and styled it to stretch and occupy the whole screen
– Hid all other elements (header, footer, etc)
– Loaded the above page with jquery as an iframe and styled the iframe itself to look like a modal
– After the form submission I look for the $_GET[‘updated’] and if true, I load an inline script to remove the modal
This way, I don’t need to leave my current page, nor do I have to lead the
acf_form_head() where not needed.
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
© 2022 Advanced Custom Fields.