I have Wordpress installed on my website, which I normally edit in dreamweaver. I use a few plugins in wordpress that are extremely useful; normally these generate their own page and I either use an iframe to link to it, or it generates code that I can use independently.
The decision has been made to move from our current contact form, a simple php mailer, to Contact-Form-7. This is so the contact form can be changed by people who aren't necessarily programmers and for its ability to integrate with other programs.
I already have a contact page, so I ideally I would like to keep that and have the contact form sit in there.
Initially, I thought it would be possible to just call the plugin using a php page using [contact-form-7 id="6" title="Contact form 1"]
. This ,of-course, wouldn't work as the "contact.php" page was out with the wordpress loop.
After a bit of research I tried using
<?php echo do_shortcode('[contact-form-7 id="6" title="Contact form 1"]') ?>
This gave nothing. I then tried using
<?php include ('../wp-blog-header.php'); ?><?php echo do_shortcode('[contact-form-7 id="6" title="Contact form 1"]') ?>
To no avail.
So, I thought, what about including it in an iFrame within the page and having the contact form itself within a wordpress post. But, I can't get the contact form on its own without having a a lot of the current wordpress theme with it, then when I remove the CSS for the header, I loose the style of the form. I could go through the entirety of the CSS only removing stuff which affects the contact form, but this would be awfully time consuming.
Any advice on how best to proceed?