Skip Navigation

[Resolved] How to prevent CRED edit form appearing within the layout assigned to its CPT

This support ticket is created 7 years, 7 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.

Our next available supporter will start replying to tickets in about 0.98 hours from now. Thank you for your understanding.

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/Hong_Kong (GMT+08:00)

This topic contains 3 replies, has 2 voices.

Last updated by Luo Yang 7 years, 7 months ago.

Assisted by: Luo Yang.

Author
Posts
#493432
cred form.png

I am trying to: use the shortcode [cred_link_form form='37157' form_name='Edit public post' text='Edit %TITLE%' target='_self'] to present an edit link for the current post in the loop

I expected to see: The form alone when the link was clicked

Instead, I got: The form presented within the Layout which applies to the CPT of the post, which makes the form narrow; the rest of the content is unhelpful.

Is there any way to not have the layout apply when the edit form is displayed?

#493497

Hi,

You display the CRED form for edting post with a new page, see the solution of anther thread:
https://toolset.com/forums/topic/how-to-apply-layout-to-cred-edit-form/#post-278461

#493859
list with edit link.png

I'm sorry but I don't think the thread deals with the issue I have.

I am creating a list of posts by the current logged in author, with a link for them to edit each post per screenshot 1

This is achieved with the following loop:

<td>[wpv-post-date format="j M"]</td>
<td>[wpv-post-title]</td>
<td>[cred_link_form form='37157' form_name='Edit public post' text='Edit %TITLE%' target='_self']</td>
<td>[cred_delete_post_link text="Delete" action="delete"]</td>

I don't see in the thread you have linked to what tells me how to make the edit link NOT open up the form in the layout for the post but to open it up on its own. Sorry if I am missing something.

Specifically, I am NOT putting the edit link into the post layout itself.

#494212

For example, you have already setup 1~3 steps of the solution:
https://toolset.com/forums/topic/how-to-apply-layout-to-cred-edit-form/#post-278461

and the target page ID is 123, you can replace this line in your codes from:

[cred_link_form form='37157' form_name='Edit public post' text='Edit %TITLE%' target='_self']

To:

<a href="[wpv-post-url id=123]?post_ids=[wpv-post-id]" target="_self">Edit</a>

If you still need assistance for it, please provide a test site with same problem, I can setup a demo for you.

This ticket is now closed. If you're a Toolset client and need related help, please open a new support ticket.