Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New Coder
    Join Date
    Mar 2012
    Posts
    26
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Stop page from refreshing after Submit button hit?

    So here is the site. Doerstv.com. If you click on the prayer request on the right tab under the social media area it will take you to a contact from. I just want the page to not refresh after they press submit. I am using the fast secure contact forms plugin for wordpress

    Hopefully there is a css fix for this so that I do not have to go searching for it through code.

    Thank you for the help

  • #2
    Master Coder felgall's Avatar
    Join Date
    Sep 2005
    Location
    Sydney, Australia
    Posts
    6,628
    Thanks
    0
    Thanked 648 Times in 638 Posts
    Quote Originally Posted by AlexG View Post
    So here is the site. Doerstv.com. If you click on the prayer request on the right tab under the social media area it will take you to a contact from. I just want the page to not refresh after they press submit. I am using the fast secure contact forms plugin for wordpress

    Hopefully there is a css fix for this so that I do not have to go searching for it through code.

    Thank you for the help
    So you don't want the page to be submitted when the submit button is pressed. The easiest way to do that is to remove the form.

    If you want the form to be processed then the information in the form has to be sent to the server and a new page loaded that has processed the form. The only way around that is to use JavaScript to handle the submit but that will only work for those visitors who have it enabled - for those without JavaScript (somewhere between 5% and 10% of your visitors) the page needs to reload in order to process their data even if you do provide a javaScript alternative for the rest.
    Stephen
    Learn Modern JavaScript - http://javascriptexample.net/
    Helping others to solve their computer problem at http://www.felgall.com/

    Don't forget to start your JavaScript code with "use strict"; which makes it easier to find errors in your code.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •