Skip Navigation

[Resolved] CRED shortcodes not displaying form for me

This thread is resolved. Here is a description of the problem and solution.

Problem: Several shortcodes are not working properly for me. The code appears on my live site instead of the rendered output.

Solution: Ensure that your code uses the proper single and double quotation marks. If you have copy + pasted code from another program, like Microsoft Office, Google Docs, or an email client, it's possible the wrong quotation marks have been inserted. For example (WRONG - curly quotes):

[credform class='cred-form cree-keep-original']
[cred_field field='form_messages' value="]

For example (RIGHT - straight quotes):

[credform class='cred-form cree-keep-original']
[cred_field field='form_messages' value='']

Some software will automatically switch straight quotes to curly quotes, which will not function the same way in code. To fix this problem, manually re-type the quote marks in your code editing area. Straight quote marks will be used, and your shortcodes should begin to function as expected.

This support ticket is created 6 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
8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 - -
13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 - -

Supporter timezone: America/New_York (GMT-04:00)

This topic contains 3 replies, has 2 voices.

Last updated by Chris Tobin 6 years, 11 months ago.

Assisted by: Christian Cox.

Author
Posts
#526767
Screen Shot 2017-05-21 at 2.51.34 PM.jpg

I am trying to:
display a CRED form in a page
I visited this URL:
hidden link
I expected to see:
The form
Instead, I got:
[credform class=’cred-form cree-keep-original’]
[cred_field field=’form_messages’ value=”]

[cred_field field=’form_submit’ value=’Submit’ urlparam=]
[cred_generic_field field=”gmail” type=”email” class=””]
{
“required”:0,
“validate_format”:0,
“persist”:0,
“default”:””
}
[/cred_generic_field]

[cred_field field=”mobile” post=”agent” value=”555-1234″]

[/credform]

I expected to see a rendered form not the short codes. It is my first cred form.
thanks!

#526794

Hi, it looks like curly quote marks are being used, which could be breaking your shortcodes. Sometimes this happens if you copy and paste from another program, like Microsoft Word or Google Docs. Those programs convert simple quote marks like ' or " into curly quotes, which look better for printing but don't function exactly the same way for code. There's an article here that has some pictures explaining the difference:
hidden link

Please ensure that your quotation marks are simple quotation marks instead of curly quotes. You may have to edit the post where you have placed this code to replace the quote marks correctly. If you simply retype them in the Visual Editor area, your shortcodes should begin to function as expected. As a test, you may only want to modify one shortcode at a time, so you can be certain this is the real source of the problem.

If not, please let me know and I will take a closer look.

#526810
Screen Shot 2017-05-21 at 4.43.53 PM.jpg

Hi,
I think I am using the right type of quote on this page of one short code.
( I copied the quote from a wp-types example at https://toolset.com/documentation/user-guides/cred-shortcodes/ )

I am not using templates or layouts yet because my theme is not set.

[credform class=’cred-form cred-keep-original’]
[cred_field field=’form_messages’ value=’msg’]
[/credform]

located at:
hidden link
thanks!

#526815
Screen Shot 2017-05-21 at 5.56.32 PM.png

Hi, as you can see in the attached screenshot, the quotation marks are incorrect. I'm including a screenshot that shows your code, followed by the correct code, so you can see the difference. For some reason, the quote marks on this page are curly instead of straight.

- First, try to copy + paste the following code instead:

[credform class='cred-form cred-keep-original'] [cred_field field='form_messages' value='msg'] [/credform]

Is the problem resolved now?

- If this does not work, you may have another 3rd-party plugin or theme modifying quotation marks. Sometimes this is a problem with special typography plugins. As a test, please disable any 3rd-party plugins and enable a default theme like Twenty Seventeen. Then retype the quotation marks in your shortcodes, or copy and paste the code above. Is the problem resolved now?

- If neither of these steps resolve the problem, I will need to take a look in your wp-admin area. If that's okay, please provide login credentials for me in the private reply fields here. I will log in and see if I can determine the problem, and we can go from there. Thanks!

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