Tell us what you are trying to do? I'm trying to add a delete post link to a page displaying a series of custom posts.
Is there any documentation that you are following? CRED documentation & shortcodes
Is there a similar example that we can see? If you log into this site (you already have full access, etc. from prior tickets). Visit hidden link and make a new quote. Next, hit the delete button for that quote to delete it. CRED is not producing any dialog or confirmation message prior to deleting the post. Can you tell me how to add this functionality?
What is the link to your site? hidden link
Hi,
Thank you for contacting us and I'd be happy to assist.
In Forms 2.5.6, some code refactoring for performance was made and the older "cred_delete_post_link" shortcode, was replaced by the new shortcode "cred-delete-post":
https://toolset.com/documentation/programmer-reference/forms/cred-shortcodes/#cred-delete-post
The confirmation dialog feature was available in the older shortcode but not in the new one.
Example of the old shortcode usage:
[cred_delete_post_link class='cred-refresh-after-delete' text='Delete' message='Are you sure you want to delete this post?' message_after='Post deleted' message_show='1' action='trash']
Although the older shortcode and its confirmation dialog feature work at the moment, since, it has been replaced by a newer one, it is possible that it gets completely depreciated in future releases. Hence, the old shortcode should only be used, if the confirmation dialog feature is absolutely required.
regards,
Waqar
It seems buggy. It does display a confirmation. When I click OK, it displays the deleting... text in the delete button, followed by another dialog box stating that the post has been deleted with an OK button. After clicking that OK button, the page does not reload, so the post remains visible, including the 'Deleting..." text on the button until I manually reload the page.
Is there an example of code that would allow me to manage the JavaScript for this function?
Thanks for writing back.
On my test website, I'm seeing a different behavior and the page automatically refreshes, after clicking the 'Ok' button for the post deleted dialog.
Are you seeing any errors In the browser's console? Can you please share the link to the page where this delete post link can be seen?
I switched it back to the new version which has no confirmation because I needed to do a client demo. I just need a way to confirm deleting quotes before deleting them. The buggy stuff happens when I use the legacy version. I'm not demoing it anymore, so fgeel free to change it to see the issue.
Thanks for the update, but, I'm not seeing any option to add or delete quotes on the 'Rep Interface' interface page.
I'll assume that I'll have to be logged in to do that and you're welcome to share temporary admin login details, in reply to this message.
Note: Your next reply will be private and it is recommended to make a complete backup copy, before sharing the access details.
Thank you for sharing the access details, but, I'm getting the "Unknown email address" message.
Can you please check the username and password again?
I've set the next reply as private.