Skip Navigation

[Resolved] Adding address on front end form does not add marker. Back end OK

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

This topic contains 14 replies, has 3 voices.

Last updated by Christopher Amirian 8 months ago.

Assisted by: Christopher Amirian.

Author
Posts
#2696341

Tell us what you are trying to do? Get the front end form to add markers to the map when an address added. The address/es show correctly under the map but no marker. If I go to the back end admin page and add the address the marker shows on the back end and on the front end. If you use long / lat or drag the marker on the front end it works.

Is there any documentation that you are following? I do not want Google to translate everything. I thought I had code to stop translation of addresses but just now I cannot see where I added that code. I thought it was on the Listing Template. Not sure that would have anything to do with it but thought I would mention it.

Is there a similar example that we can see? hidden link I have been into admin to correct the problem with all the therapists so I do not have an example of the error. This is a live site and so I cannot show an error for long. If Therapists add their practices with addresses they never show on the map. If I add them in admin they always show. If you use long / lat they always show.

What is the link to your site? hidden link

#2696547

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+00:00)

Am I right in understanding the issue correctly?

You have Listing posts, and front-end forms for submitting and editing these posts.

They contain an address field.

And the problem is that if an address is added via a front-end form it "doesn't work", i.e. won't appear on a map where it should be added as a marker?

That suggests to me there could be an issue with the address field autocomplete not working in the front-end forms.

When someone tries to introduce an address into the address field, Google autocomplete should operate, providing address suggestions.

Does it?

Can you check the browser console for JavaScript errors when loading a page with one of these forms and trying to complete the address field?

#2697154

Again I answered this on Thursday
....................
Thanks for this.
I did a practice, adding and editing a listing on the front end, and found that the autocomplete worked just fine.
However, I was logged in as admin but using a plugin that allows me to log in AS user and it all worked fine. So now I will create a new user without any admin rights and test again. Presently every time a Therapist User adds a listing, the map shows the address but not the marker. So maybe it has something to do with the user roles. It was working fine and then it stopped at the time I was addressing the Google translate issue.
Let me do some more tests.
Thanks again for your help – much appreciated.
Tim

Please let me know that you receive this response

#2697162

I have now done a test creating a user just the same as a therapist.
I found that the autocomplete worked just fine but when I submitted the listing the address showed correctly under the map but the marker did not appear on the map.

#2697285

Christopher Amirian
Supporter

Languages: English (English )

Hi there,

Thank you. I added a sample user and I see the issue. I might be the fact that you added the therapist users with the subscriber user role and you might need to make them more than a subscriber but I am not sure.

That is why I asked the second tier support to test this.

I will get back to you as soon as I have an answer from them.

Thank you.

#2697653

Christopher Amirian
Supporter

Languages: English (English )

Hi there,

The second tier support needs help to understand how the address is stored which seems to be the source of the issue.


The client is using Gtranslate plugin for the site to be multilingual.

I don't recognise the language from the above screenshots for "Germany" in the address.

But in the language switcher dropdown the only non-Latin character language is Chinese, which it clearly isn't.

I tried using a VPN for some non-Latin language like Russia and loading and submitting the form to create a new listing, and the address is given in English and stored with "Germany".

This looks to be the source of the problem, but I'm having problems reproducing it.

Can you check with the client about how it is that the addresses are being generated and stored in that language?

Thanks.

#2697730

I will look into ensuring that the address is not translated by Google. It was working and then it stopped.
Can you tell me why I do not get any email notifications when content is added to support? I have to log into Toolset support to read responses.
That is not very efficient.
I will see if I can work something out myself.
Please be sure to send emails when content is added to this ticket

#2697739

Can I add a class in here
[cred_field field='address' force_type='field' class='form-control' output='bootstrap' isRepetitive='true']
Should I add it like this
[cred_field field='address' force_type='field' class='form-control' class="notranslate" output='bootstrap' isRepetitive='true']
Or can I put that whole section in a span?
<span class="notranslate">[cred_field field='address' force_type='field' class='form-control' output='bootstrap' isRepetitive='true']</span>

This class stops Google from translating content.
Thanks
Tim

#2697828

I tried all of the above and it didn't work. I disabled the Gtranslate plugin. Still didn't work.
If I move the marker and select USE THIS ADDRESS - it does not work
If I move the marker and do not click on USE THIS ADDRESS but just hit submit - IT WORKS.

#2697927

Christopher Amirian
Supporter

Languages: English (English )

Hi there,

I am not sure why the emails are not reaching to you, when we answer the emails is automatically sent. Maybe you can check the spam folder of your email client?

I relayed the information to the second-tier about the last three points you mentioned and waiting for the answer.

#2698802

Christopher Amirian
Supporter

Languages: English (English )

Hi there,

Unfortunately the user/pass you have provided before is not in admin user role anymore, that is why our second tier support can not investigate the issue.

Would yu please set the next reply as private and give the login info of an administrator role?

Also we need your permission to create a copy of the website if needed.

Thanks.

#2698839

Christopher Amirian
Supporter

Languages: English (English )

Thank you Tim. I copied the website and reported to the second-tier support.

I will get back to you as soon as I have an update.

Thanks.

#2699446

Christopher Amirian
Supporter

Languages: English (English )

Hi there,

Thank you for your patience, we copied the website to our server and if you check it works with no issues with Therepist test user:

hidden link

You can login with the some admin and therapist user info and see the result there yourself.

It seems the issue is happening on your server only. You can check with your hosting service provider and see if they can help you find a clue?

Maybe there is a must use plugin forced on the website that causes the issue or something like that. But I am not sure and not qualified to judge.

Thanks.

#2699761

I can see that it is working on your test site. I am now wondering about PHP versions and server side caching or any other server variable.
I thank you for your rigorous testing and will take it up with Dreamhost.
Thanks
Tim

#2699776

Christopher Amirian
Supporter

Languages: English (English )

My pleasure Tim. I hope that you find a solution with your hosting service support help.