Shortcode not working in page
-
Hello,
I have a page that uses custom shortcodes to check if a user is logged in, so it will display a login form if he isn’t.
For the members area of the shortcode, I have placed the shortcode for Contact Form 7, as you can see in the code below:
[visitor] <div class="boxes" style="margin-top:-10px;"> <div class="box span4" id="box_content_left" style="min-height:560px;"> <h2 style="font-size:1.4em;">Login</h2> [insert_php] login_with_ajax(); [/insert_php] </div> [/visitor] [member] <div class="boxes" style="margin-top:-40px;"> <div class="box span4" id="box_content_left" style="min-height:560px;"> <h2 style="font-size:1.4em;">Logged in</h2> <p>Contact us in the logged in area:</p> <br/> [contact-form-7 id="371" title="Logged-in Contact English"] </div> [/member]When I run the page I see the contact-form-7 shortcode instead of the form. It works fine in other pages, I even tried another form that’s working now, and the same happens to it. Only when I use Insert PHP plugin together with the do_shortcode(‘[contact-form-7]’) function, it works fine, but that’s not the best solution.
Does anyone know what happens here?
Thanks for your support!
Diego
The topic ‘Shortcode not working in page’ is closed to new replies.