[Resolved] Insert “Edit” link to Cred form into single-product.php

This is the community support forum for Types plugin, which is part of Toolset. Toolset is a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients and people who registered for Types community support can post in it.

Our next available supporter will answer your ticket in about 7.58 hours from now. Thank you for your understanding.

This thread is resolved. Here is a description of the problem and solution.

Problem:
Display CRED Edit form for Products and "Edit" link below the WooCommerce product description in the single-products.php template file.

Can we use the below shortcode in a php template file (e.g. WooCommerce single-product.php)?

[toolset-edit-post-link content_template_slug="cred-edit-form-in-ct"]Edit %%POST_TITLE%%[/toolset-edit-post-link]

Solution:
No, at moment CRED Edit form shortcode can not be executed in WooCommerce single-product.php -- it is submitted as a feature request for further consideration. However, this shortcode works fine in normal post template php files.

1. Alternatively, display CRED editing forms for Products using standard Toolset method which works great:
https://wp-types.com/documentation/user-guides/displaying-cred-editing-forms/

2. OR you may want to use Views shortcode “Post edit link”.

[wpv-post-edit-link text="Edit Item"]

This does not work as frontend edit form but just gives a link that will take user to backend editor.

Some testing notes:
- This shortcode [toolset-edit-post-link] works when we insert directly in Product's body content / Product Description editor (NO Views CT).

- This shortcode [toolset-edit-post-link] also works when we add it in single.php file (Posts) and single-book.php file (CPT).

Relevant Documentation:
- https://wp-types.com/documentation/user-guides/displaying-cred-editing-forms/
- [toolset-edit-post-link] shortcode and its attributes are mentioned here:
https://wp-types.com/documentation/user-guides/views-shortcodes/#toolset-edit-post-link

Related documentation:

This topic contains 17 replies, has 2 voices, and was last updated by  Cec1413 3 months, 4 weeks ago. The support staff assigned to this topic is Noman.

Viewing 3 posts - 16 through 18 (of 18 total)
Author
Posts
#549589

Noman
Forum moderator

Supporter languages: English (English )

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

Issue #2: WC products post type does not appear to be manageable by Toolset
==> Please kindly open a new ticket if you need help with this and assign the new ticket directly to me or just send me the link here, I will let you know the way to enable this. It will help other users with similar problems to find solutions when searching the forum, I am not allowed to handle multiple issues in the same ticket as per support policy. https://wp-types.com/toolset-support-policy/

For other main issue, I would love to tell you some alternative way, but at moment I don't have any. If I get some possible way from our team I will let you know for sure. Only possibility at moment is to use WC Views >> Content Template for products and find a way to add 3rd party shortcode in there somehow (plugin that had no shortcode, you can create a custom shortcode for that), I imagine that would be easier than working around this current limitation we are running into.

Thank you

#550786

Noman
Forum moderator

Supporter languages: English (English )

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

Hi, Just wanted to send an update that our 2nd tier and development team has informed that this will be added as feature request (or we can say compatibility request). So I have submitted this as a feature request for further consideration.

So right now the best approach would be to use View's Content Template if you would like have this frontend edit capability for Products, which may or may not be ideal for your current setup.

Thank you

#551876

Thanks for the update, Noman. I'll start a new topic for the other issue, which I hadn't realised was an issue 😛

Viewing 3 posts - 16 through 18 (of 18 total)