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 4 of 4
  1. #1
    New to the CF scene
    Join Date
    Apr 2010
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Javascript form with validation and summary page

    Hello Coding Forum gurus, I'm hoping to find some help here with a javascript order form. I am currently working on a javascript form that requires field validation as well as a summary page (order confirmation) after every field is entered correctly. At this point I am satisfied with the field validation portion of the script, however, I am not sure how to call a function to display the summary page.


    here is a description of my dilemma:

    To begin, the field validation functions are called by the form's onsubmit event handler. Which then works it way through several text field validation functions. After the script finishes validating and checking each field for acceptable input, how do I call a function to display a summary page of the order form?




    On a side note, the only programming experience I have ever had is with javascript. I have never taken any other programming classes, and I am fairly new to this. Any help would be appreciated.

    Not sure if I am allowed to post the entire script here or not but I'd be willing to send to anyone that would like to take a look, HUGE THANK YOU in advance to anyone that takes time out of their busy schedules to take a look.

  • #2
    d_s
    d_s is offline
    New Coder
    Join Date
    Mar 2010
    Location
    India
    Posts
    52
    Thanks
    0
    Thanked 8 Times in 8 Posts

    Smile summary page scripts

    Hi,

    You can get this job done with a simple PHP script. Any way, if you are submitting the order details to a database, you can use php.

    here is what it might look like.

    On the onsubmit() event handler, use the following code as

    Code:
    orderForm.submit();
    the form tag can be modified so that it calls a php script like
    Code:
    action="orderSummary.php"
    In that php page, you may get the order details and then use to geneate a summary form.

    If you would like to have a look at the code, do checkout my blog at :
    http://dsaravanan.wordpress.com/2010...submit-in-php/

    regards

    d_s.

    Quote Originally Posted by mjolnir View Post
    Hello Coding Forum gurus, I'm hoping to find some help here with a javascript order form. I am currently working on a javascript form that requires field validation as well as a summary page (order confirmation) after every field is entered correctly. At this point I am satisfied with the field validation portion of the script, however, I am not sure how to call a function to display the summary page.


    here is a description of my dilemma:

    To begin, the field validation functions are called by the form's onsubmit event handler. Which then works it way through several text field validation functions. After the script finishes validating and checking each field for acceptable input, how do I call a function to display a summary page of the order form?




    On a side note, the only programming experience I have ever had is with javascript. I have never taken any other programming classes, and I am fairly new to this. Any help would be appreciated.

    Not sure if I am allowed to post the entire script here or not but I'd be willing to send to anyone that would like to take a look, HUGE THANK YOU in advance to anyone that takes time out of their busy schedules to take a look.
    regards

    d_s.

  • #3
    New to the CF scene
    Join Date
    Apr 2010
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts
    D_S, thanks for the info, much appreciated but in this case the form has to be completed with javascript. Thanks for the input though.

  • #4
    Regular Coder
    Join Date
    Nov 2009
    Posts
    247
    Thanks
    4
    Thanked 22 Times in 22 Posts
    See attached.
    Attached Files Attached Files


  •  

    Posting Permissions

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