Answer the question
In order to leave comments, you need to log in
Contact Form 7 one form replaces the content of another!?
I ran into a problem when using Contact form 7.
There is already an existing, live form on the page in the carcass. But there was a need to add another form to the header.
I create a new form from the WP admin, set the submit, even give unique field names (a la [text text-565]). I save the form and accordingly insert a unique shortcode <?php echo do_shortcode('[contact-form-7 id="46" title="NewForm2"]'); ?> to a pre-prepared place where this form should take place.
And then a strange, inexplicable, and unknown thing happens.
The form that already exists on the page, with its own unique field names, with its own ID (<?php echo do_shortcode('[contact-form-7 id="45" title="NewForm"]'); ?>) changes all its fields , to the fields of the new form. Can someone explain the phenomenon, and suggest where to dig?
Answer the question
In order to leave comments, you need to log in
I figured it out myself, the forms were influenced by a piece of JS code affecting the .wpcf-form class .... I rewrote it, the problem disappeared.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question