Skip Navigation

[Resolved] Using custom confirmation messages causes delete post shortcode to fail.

This support ticket is created 4 years, 11 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
- 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 2 replies, has 2 voices.

Last updated by ericE-4 4 years, 11 months ago.

Assisted by: Waqar.

Author
Posts
#1499101

I am trying to use custom text for the confirmation message and the post-deletion feedback. Using the documentation here: [https://toolset.com/documentation/user-guides/front-end-forms/cred-shortcodes/#cred_delete_post_link] I added the message and message_after attributes to the shortcode. When I do that, the shortcode no longer works (clicking on the link does nothing. If I remove the messages, the link again works.

Initial shortcode (works):

[cred_delete_post_link post="[wpv-post-id]" text="Delete this target species" action="delete" class="cred-refresh-after-delete"]

Edited shortcode (does not work):

[cred_delete_post_link post="[wpv-post-id]" text="Delete this target species" action="delete" message="Are you sure you want to permanently delete this target species and it's availability calendar (if present)?" message_after="Species deleted." class="cred-refresh-after-delete"]
#1501543

Hi Eric,

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

During troubleshooting, I noticed that the issue seems to be with the use of the apostrophes in the "message" attribute.
( i.e. Are you sure you want to permanently delete this target species and it's availability calendar (if present)? )

You can switch to a different character ( i.e. ʼ instead of ' ) and the delete link will work:


[cred_delete_post_link post="[wpv-post-id]" text="Delete this target species" action="delete" message="Are you sure you want to permanently delete this target species and itʼs availability calendar (if present)?" message_after="Species deleted." class="cred-refresh-after-delete"]

This is similar to the note at:
https://toolset.com/documentation/user-guides/views/conditional-html-output-in-views/#field
( screenshot: hidden link )

I've also shared this with the concerned team so that a similar note can also be included in the documentation of "cred_delete_post_link" shortcode.
( https://toolset.com/documentation/user-guides/front-end-forms/cred-shortcodes/#cred_delete_post_link )

regards,
Waqar

#1502325

Thanks. Unfortunately, I only have the one apostrophe character on my keyboard, but I copied and pasted the character you supplied (the one that looks like a curved apostrophe), and it works. I'm not sure what the ASCII code is for that character, but whatever it is, you might want to add that to the documentation.