Support » Plugin: Contact Form 7 » What is wrong with this code?

  • I tried the following code and testing it, it doesn’t work. My website is http://www.garagedoormadisonwi.com

    <div class="our-form">
        <div class="row">
            <div class="col-sm-6 col-md-6">
                <div class="form-group">
                    [text* name class:form-control placeholder "Name"]
                    <div class="input-bottom-line"></div>
                </div>
            </div>
            <div class="col-md-6 col-sm-6">
                <div class="form-group">
                    [email* email class:form-control placeholder "Eamil"]
                    <div class="input-bottom-line"></div>
                </div>
            </div>
        </div>
        <div class="row">
            <div class="col-md-6 col-sm-6">
                <div class="form-group">
                    [text* address class:form-control placeholder "Address"]
                    <div class="input-bottom-line"></div>
                </div>
            </div>
            <div class="col-md-6 col-sm-6">
                <div class="form-group">
                    [tel* phone class:form-control placeholder "Phone"]
                    <div class="input-bottom-line"></div>
                </div>
            </div>
        </div>
        <div class="row">
            <div class="col-sm-12 col-md-12">
                <div class="form-group">
                    [textarea message class:form-control placeholder "Message"]
                    <div class="input-bottom-line"></div>
                </div>
            </div>
        </div>
        <button type="submit" class="red-button bgcolor">
            [submit "submit"]
        </button>
    </div>
    • This topic was modified 4 years, 2 months ago by palpulla.
Viewing 3 replies - 1 through 3 (of 3 total)
  • Hey palpulla, I’m also new to CF7 but I wanted to try to help.

    If that file your editing is a php file, you can’t execute WordPress shortcodes that way.

    You have to call them this way:

    <?php echo do_shortcode( '[contact-form-7 id="1234" title="Contact form 1"]' ); ?>

    I found that solution on the FAQ. Hope that helps!

    Thread Starter palpulla

    (@palpulla)

    Thank you! Where should I add that code to?

    Hi!

    First of all. May i know what plugin you use to send Email? Like Post SMTP plugin or WP-Mail-SMTP?

    Thanks.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘What is wrong with this code?’ is closed to new replies.