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
    Sep 2004
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Simply to redirect form content on Another Page

    The below script doesnt let me display the contents of the form to another page can someone suggest a wa y to redirect the contents as suggested to open in another page after the submit button is pressed .... help much appreciated

    <html>

    <head>
    <title>[No Title]</title>
    <script language="JavaScript">
    <!--

    function checkRequired(theForm)
    {
    var bMissing = false;
    if ( 0 == theForm.textField.value.length )
    bMissing = true;

    if ( 0 == theForm.dropMenu.selectedIndex )
    bMissing = true;

    if ( bMissing )
    {
    alert( "All form fields are required.\n"
    + "Please complete them and Submit again.");

    return false;
    }
    else
    {
    return true;
    }
    }

    //-->
    </script>
    </head>

    <body>

    <form>

    <p>Name : <input type="text" name="textField" size="20"><br>
    Address : <input type="text" name="textField" size="20"><br>
    Phone : <input type="text" name="textField" size="20"><br>

    <select size="1" name="dropMenu">
    <option selected value>Select One</option>
    <option value="1">Male</option>
    <option value="2">Female</option>
    </select><br>

    <input type="submit" value="Submit" name="submit"> &nbsp;
    <input type="reset" value="Reset" name="reset"></p>

    </form>

    </body>

    </html>

  • #2
    Senior Coder
    Join Date
    Jun 2002
    Location
    Wichita
    Posts
    3,880
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Your <form> tag needs an "action" property specifying the name of the page you want to load next.
    Check out the Forum Search. It's the short path to getting great results from this forum.


  •  

    Posting Permissions

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