Skip Navigation

[Resolved] Adding Buttons to View Template

This support ticket is created 5 years, 4 months 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
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10: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/Kolkata (GMT+05:30)

This topic contains 2 replies, has 2 voices.

Last updated by kaiD 5 years, 4 months ago.

Assisted by: Minesh.

Author
Posts
#1290431

Tell us what you are trying to do?
i like to add a button to a view template. The content for the button text and also for the link of the button should come from custom fields. So i´ve created a custom field for the Linktext (type: single line) and one for the Link URL (type: URL)
How am i able to create now a button which uses the content of the to fields.

Example:
I like to display a grid of a specific post type. Each item in the grid should show the informations: Picture, Heading, and a button with a linktext and link which i specified via custom fields in the post type

F.E. One Post Type will have a link with the text "One" and the link "www.one.de" another one will have the linktext "Two" and the url "www.two.de"

Is there any documentation that you are following?
No i did not find a documentation

Is there a similar example that we can see?

What is the link to your site?

#1290435

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

What if you try to follow the simple HTML anchor tag::

<a href="[types field='url-field-slug' output='raw'][/types]"> [types field='Linktext-field-slug' ][/types] </a>

Then add some class to format the anchor like button.

#1290495

Hi,

thanks for the quick response.
I´ll check it out.

Kai