Skip Navigation

[Resolved] I want to insert a cred form in a slider with php using a template file

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

Tagged: 

This topic contains 2 replies, has 2 voices.

Last updated by felixP-3 5 years, 5 months ago.

Assisted by: Christian Cox.

Author
Posts
#1144415

I am doing this : echo \do_shortcode('[cred-form form="632"]'); in a slider that is using a template file

and the cred form shows up, but all the formatting is wrong.

When I use the same cred form in a page, it works fine.

How do I get the cred form to show up with the correct formatting in a template file?

#1144514

in a slider that is using a template file
Hi, it depends on what you mean by "using a template file". If the Form markup is correct but the styles are not, then it could be:
1. The stylesheets required by Forms are not being enqueued correctly because Forms doesn't recognize that you have placed the Form anywhere on the page
2. The stylesheets used by Forms are enqueued but they are being overridden by other stylesheets applied by your template
3. AJAX is being used to update the slider and Forms on those AJAX updated slides are not initialized correctly
4. Something else I can't predict

If the problem is #2, then you can remove the conflicting styles applied by your template. If the problem is #1, then it's not so straightforward. You can try enqueueing the stylesheets manually, you can try changing the way the Form is added to the slider, or you can try adding the Form somewhere it will be recognized by the Forms plugin like a Content Template for this page. Then you can hide that Form with CSS.

#1146629

My issue is resolved now. Thank you!

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