WordPress.org

Ready to get started?Download WordPress

Forums

[Plugin: Contact Form 7] Submitting without js goes to 404 (9 posts)

  1. Dave Redfern
    Member
    Posted 3 years ago #

    Hello all,

    I have disabled css and js from loading into my site. It appears that because of this when I submit Contact Form 7 it goes to a 404.

    The actual form works and I successfully receive the email, it just doesn't return to the correct address.

    I have read about this problem on google but the solution for most is to have wp_footer(); in the template which I already have.

    Does anyone have any ideas?

    Thanks

    Dave.

    http://wordpress.org/extend/plugins/contact-form-7/

  2. dcloud
    Member
    Posted 3 years ago #

    Hi Dave, I'm having the same problem. Although I am not sure if I have CSS or JS disabled. I only noticed the problem after I installed Windows 7, which I don't think has any impact on CF7 on my site, but it just seems odd.

    I even have the correct "thank you" page URL added to "aditional settings" (on_sent_ok: "location.replace('http://dougdraws.com/thank-you/');") which always worked before. But it doesn't work now.

    I wonder if this started after the last plugin update?

  3. Takayuki Miyoshi
    Member
    Posted 3 years ago #

  4. dcloud
    Member
    Posted 3 years ago #

    I think this behavior started after the last update. I fixed mine by deleting the 'on_sent_ok:' line from the Additional Settings box and replacing it with "Your message was sent successfully. Thanks."

    I got this line from the ones supplied in the "Messages" box right above it (you have to expand that box to see the default messages).

  5. Dave Redfern
    Member
    Posted 3 years ago #

    Hello and thanks for all your responses.

    @takayukister: yes I was using the reserved name but it is still not working despite changing this.

    @dcloud: I tried adding that but it still doesn't work.

    I have the following:

    <label>Your Name</label>
    <div>[text* your-name]</div>
    <label>Your Email Address</label>
    <div>[email* your-email]</div>
    <label>Comments</label>
    <div class="ta">[textarea* your-comments]</div>
    [submit id:send]

    I also have the following options in my wp-config:

    define('WPCF7_LOAD_JS', false);
    define('WPCF7_LOAD_CSS', false);
    define('WPCF7_AUTOP', false);

    Any help is much appreciated.

  6. benjhaisch
    Member
    Posted 3 years ago #

    Mine is doing the same thing, but it will work probably 8/10 times. I'm totally confused.

    All fields are required, and the email has to be valid. I just don't get it.

  7. Takayuki Miyoshi
    Member
    Posted 3 years ago #

    When you can't make it work, I'd suggest to show your page's URL. Someone might find the cause of your problem.

  8. tovlakas
    Member
    Posted 3 years ago #

    The cause of this problem is a bug with the plugin, not an issue with the person's page. Adding an ID to the submit button (or class or label, for that matter) causes the javascript to break. the only thing that works is a vanilla "[submit]" call.

    takayukister, please update your FAQ documents if you could regarding this issue—hopefully it will save someone else from having to spend the entire day troubleshooting it themselves like I had to do. Thanks!

  9. koolsol
    Member
    Posted 3 years ago #

    i sorted this by adding the below function in footer.php file

    wp_footer();

    Note wp_footer(); function should be in php tag like:

    <?php wp_footer();?>

Topic Closed

This topic has been closed to new replies.

About this Topic