Passer la navigation

[Résolu] How to add Edit button

This support ticket is created Il y a 2 years, 1 month. 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 -

Fuseau horaire du supporter : Asia/Karachi (GMT+05:00)

Ce sujet contient 1 reply, a 2 voix.

Dernière mise à jour par Waqar Il y a 2 years, 1 month.

Assisté par: Waqar.

Auteur
Publications
#2695348

I found instructions on how to add an "Edit" link to a post template.
Is it possible change the link to a button?

#2695374

Hi,

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

The shortcode for the edit link 'toolset-edit-post-link', doesn't support changing the HTML for it from a link ('a' tag) to a button (button tag).

However, you can use the 'class' attribute to assign a custom class to it, and make the link look like a button.
( ref: https://toolset.com/documentation/programmer-reference/forms/cred-shortcodes/#toolset-edit-post-link )

Example:


[toolset-edit-post-link content_template_slug='ct-for-books-edit' target='self' class="button"]Edit[/toolset-edit-post-link]

Most themes offer built-in class names like 'button' or 'btn' etc, to style the HTML elements like standardized buttons. If you don't have this on your website, you can also use custom CSS code for such styling.

regards,
Waqar