I am trying to add a cred edit form to a product page like so:
[wpv-conditional if="( '[wpv-post-status]' eq 'draft' )"]
[cred_form form='campaign-form-publish']-
[/wpv-conditional]
However, this just outputs the literal shortcode when the product is still a draft
I put this inside a content template and I am also using the layouts plugin.
This is for product pages so woocommerce views is involved too.
Do you mind testing this out on your end?
When I remove the conditional sentence the form is displayed properly.
Please help. Do you also get the literal shortcode?
I use the latest versions of the toolset plugins.
Regards,
Nick
Minesh
Supporter
Languages:
English (English )
Timezone:
Asia/Kolkata (GMT+05:30)
Hello. Thank you for contacting the Toolset support.
Well - could you please share screenshot of your layouts page where you added above conditional shortcode ?
Yes in the meantime do you mind testing it out on your end?
Do you see the shortcode in the screenshot? This is on the layouts page. In the screenshot ou see the content template added to the layout. there's only one added.
[wpv-conditional if="( '[wpv-post-status]' eq 'draft' )"]
[cred_form form='campaign-form-publish']</div>
[/wpv-conditional]
Minesh
Supporter
Languages:
English (English )
Timezone:
Asia/Kolkata (GMT+05:30)
Well - I just tested it and it just works fine.
I've just replace the my test form within the conditional statement and it just rendered fine:
[wpv-conditional if="( '[wpv-post-status]' eq 'draft' )" debug="true"]
[cred_form form="create-new-state-form"]
[/wpv-conditional]
This is what I got
####################
wpv-conditional attributes
####################
Array
(
[if] => ( draft' = 'draft' )
[debug] => true
)
####################
Debug information
####################
--------------------
Original expression: ( draft' = 'draft' )
--------------------
Can I give you access to my site?
Minesh
Supporter
Languages:
English (English )
Timezone:
Asia/Kolkata (GMT+05:30)
Yes - sure.
Please share problem URL and access details.
I have set the next reply to private which means only you and I have access to it.