Skip Navigation

[Resolved] Make a single field into a link

This support ticket is created 4 years ago. There's a good chance that you are reading advice that it now obsolete.

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.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Karachi (GMT+05:00)

This topic contains 3 replies, has 2 voices.

Last updated by Waqar 4 years ago.

Assisted by: Waqar.

Author
Posts
#2013945

Hi,
I'm using elementor to build custom templates for my listings. I want to show a phone number, website and email for each listing.
I can easily get the website to be a link since it is set as an URL field, but I can't figure out how to make the phone number and email address also into a clickable link.

Any suggestion on how to do this? I don't want to use a Toolset view, but the elementor template.

#2014427

Hi,

Thank you for contacting us and I'd be happy to assist.

To show Toolset Types' custom fields as links in the Elementor templates, you can use Toolset Types Fields shortcodes:
https://toolset.com/documentation/customizing-sites-using-php/functions

For example, if you have a Phone type custom field with slug "phone-number", its link with the Types field shortcode would look like this:


<a href="tel:[types field='phone-number' output='raw'][/types]">[types field='phone-number' output='raw'][/types]</a>

And, for an Email type custom field with slug "email-address", the link with the Types field shortcode would be:


[types field='email-address' title='Send an email'][/types]

Note: You can place this code, in any Elementor widget that supports HTML and shortcodes.

I hope this helps and please let me know if you need any further assistance around this.

regards,
Waqar

#2021203

Thank you, this helps a lot with regards to the phone number.
I have a follow up question about the same type of problem.
On each of my profiles page I'd like to add a contact form that sends an email to the owner of the profile. Is this possible using toolset forms or do you recommend a plugin and then try to code in the shortcode in the plugins html code?

New threads created by Waqar and linked to this one are listed below:

https://toolset.com/forums/topic/split-contact-form-that-sends-an-email-to-the-owner-of-the-profile/

#2021933

Thanks for the update and glad that my message helped.

I've split a new ticket for your question about the contact form and will follow up on it separately.
( ref: https://toolset.com/forums/topic/split-contact-form-that-sends-an-email-to-the-owner-of-the-profile/ )

You're welcome to mark this ticket as resolved and start a new one for each new question or concern.