But now as I'm working on the post edit form, I'm running into issues.
I'm using elementor so I'm using the shortcode: [cred_form form='post-edit-startups' post='[wpv-search-term param=“post_id”]
The link to edit the post is: hidden link;
It worked for minute and then started displaying: "Form type and post type do not match" -- I've looked through every post on here about that error, and normally it's because the category wasn't matched correctly, or wordpress needed updates. All of my plugins are up to date, and it's mapped correctly.
Looks like the Elementor page builder is having difficulty handing the shortcodes within the shortcode.
(i.e. where one shortcode's output is used as the attribute of another shortcode)
Here is a workaround that you can use:
1. You can register a new custom shortcode, which can get the target post ID from the URL parameter, use it in the form's shortcode, and then return the form's output, all using a single shortcode:
> Could it take some time for it to implement the code?
- Unless some aggressive cache or code optimization is in place, the code should start working right away.
Can you please share temporary admin login details, along with the link to the page where you're trying to use this shortcode? I'll be able to troubleshoot and suggest the next steps, accordingly.
Note: Your next reply will be private and making a complete backup copy is recommended before sharing the access details.
The edit link on the 'My Account' page, was not passing the target post's ID correctly.
In the Elementor template 'Author Loop', that generates this edit link, the link used was: hidden link;
But Elementor was not processing the [wpv-post-id] shortcode in this case and the post's ID was not getting included.
I changed that static link to 'Shortcode' and in the shortcode field included the 'wpv-post-url' and 'wpv-post-id' to generate the edit link:
( screenshot: hidden link )
[wpv-post-url item='10398']?post_id=[wpv-post-id]
Note: '10398' is the ID of the 'Edit Listing' page.