Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialEmil Wallgren
11,737 PointsNewbie question regarding Ninja Forms Modal
Hi!
My name is Emil Wallgren and I'm currently building a website where I want to use Ninja forms modal. I've created a form in Ninja Forms with the id of 5...
I don't really understand how to use the shortcodes.
The link is named Contact Us and is placed in the header and footer. But I don't seem to get it to work.
Could some nice person help me explain exactly what to do to get it to work :-)
The link to the plugin is here: https://wordpress.org/plugins/ninja-forms-modal/
Thank you sincerely! :-)
/Emil
1 Answer
Rhoda Toynbee
18,938 PointsHi Emil,
My two recommendations would be to visit the codex to get the PHP for using a short code (that's the part wrapped in square brackets): [ninja_forms_modal_form id=5 text_link="Contact Us"]
Here is a link to the codex: https://codex.wordpress.org/Function_Reference/do_shortcode
I'm not sure if the short code is already pulling in an "a href" wrap to make that whole thing a link, so wrapping the short code in an a tag might be necessary too. Something to fiddle with :)
Rhoda
Emil Wallgren
11,737 PointsEmil Wallgren
11,737 PointsThank you :-)
I got it to work by using the link. Now's the problem of putting it in a second-level wp-menu ;-)
/Emil
Rhoda Toynbee
18,938 PointsRhoda Toynbee
18,938 PointsYou can add code to a menu item, as well as a sub-menu item. That might be something to try...I think it's when you add a "link" menu or sub-menu. I don't remember exactly, but I know it can be done :)