Skip Navigation

[Resolved] Question about how custom fields treat spaces in the plugin

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 1 reply, has 2 voices.

Last updated by Nigel 9 months, 3 weeks ago.

Author
Posts
#2681885

Hello, I have a question about this project regarding the WhatsApp links, the links have text with spaces and an accent

The WhatsApp custom field is set to Phone in this project(I can't remember why it is set like that, I did it a long time ago). I think I can modify the custom field to link (I haven't done it for fear of losing information, it can be delicate)

But my question is specific, for example looking at this ad:

hidden link

Is the WhatsApp link safe? I tried placing the spaces with %20 to ensure compatibility with older browsers but they do not appear in the final url. I also have doubts regarding the accent of the message (Féminin for example)

Should I transform the custom field from phone to link? Or is it not really necessary and these links are already safe for older browsers? (in modern browsers the word is not cut and the predefined message is loaded without problems)

Thank you very much, greetings.

#2682040

Nigel
Supporter

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

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

Hi there

Clicking the Whatsapp link you currently have ultimately goes to this URL:

hidden link

The text is HTML encoded so that spaces and characters with accents are handled correctly, including by older browsers.

So it appears to be working as intended. I'm not sure that you need to make any changes.

#2682064

The result you get is for browser/Wahtsapp API correction

The plugin respects the %20 spaces and the rest of the encodings, it's just that to see them it is necessary to enter the source code of the website. The thing is that it is such an important url in the project that I want to make sure it is correct on my part, but I was able to make the necessary adjustments (I am aware that it is not necessary in modern browsers and that the WhatsApp API surely handles this right way)

I discovered because it did not occupy a URL custom field, that custom field does not tolerate shortcodes[ ]. I can imagine many scenarios where that could be a major limitation, perhaps you could review it in the future.