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 6 of 6
  1. #1
    New to the CF scene
    Join Date
    Jun 2007
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question Confirmation Page

    Here's what I am trying to do: Have a list of items for customers to create a list have the script take them to a confirmation page of sorts, where it simply lists the items they have checked, and then they can print it and be on their way. I tried to use a POST method, going from an HTML page to an ASP page in dreamweaver, following a tutorial I found here: http://dreamweaverfever.com/tutorial...rt-confirm.asp

    Here's my script from the confirm.asp page:

    <%@LANGUAGE="JAVASCRIPT" CODEPAGE="1252"%>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
    <title>Untitled Document</title>
    </head>

    <body>
    <p><%= Request.Form("OrnamentOne") %></p>
    <p><%= Request.Form("OrnamentTwo") %></p>
    <p><%= Request.Form("OrnamentThree") %></p>
    </body>
    </html>

    and now my code from the gift.html page (form only):

    <form id="form1" name="form1" method="post" action="confirm.asp">
    <label></label>
    <fieldset><legend></legend>
    <label>
    <input name="checkbox" type="checkbox" value="OranamentOne" />
    one</label>
    <br />
    <label>
    <input name="checkbox2" type="checkbox" value="OranamentTwo" />
    two </label>
    <br />
    <label>
    <input name="checkbox3" type="checkbox" value="OranamentThree" />
    three<br />
    </label>
    <input type="submit" name="Submit" value="Submit" /></fieldset>
    </form>

    Hopefully I'm posting in the correct forum. Thanks!
    Last edited by mac_guy; 06-10-2007 at 08:42 AM.

  • #2
    New to the CF scene
    Join Date
    Jun 2007
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts
    My gift.html page actually reads this: (sorry for the previously misspellings; tried to correct it, but it wouldn't let me edit)

    <form id="form1" name="form1" method="post" action="confirm.asp">
    <label></label>
    <fieldset><legend></legend>
    <label>
    <input name="checkbox" type="checkbox" value="OrnamentOne" />
    one</label>
    <br />
    <label>
    <input name="checkbox2" type="checkbox" value="OrnamentTwo" />
    two </label>
    <br />
    <label>
    <input name="checkbox3" type="checkbox" value="OrnamentThree" />
    three<br />
    </label>
    <input type="submit" name="Submit" value="Submit" /></fieldset>
    </form>

  • #3
    Regular Coder
    Join Date
    Jan 2005
    Posts
    155
    Thanks
    0
    Thanked 0 Times in 0 Posts
    you're using the wrong name in your request.Form statements. you're using the values instead of the checkbox name
    Code:
    <body>
    <p><%= Request.Form("OrnamentOne") %></p>
    <p><%= Request.Form("OrnamentTwo") %></p>
    <p><%= Request.Form("OrnamentThree") %></p>
    </body>
    should be
    <body>
    <p><%= Request.Form("checkbox") %></p>
    <p><%= Request.Form("checkbox2") %></p>
    <p><%= Request.Form("checkbox3") %></p>
    </body>[/code]

  • #4
    New to the CF scene
    Join Date
    Jun 2007
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Ok. Thanks, I've updated the code. I'm still getting a 405 Method Not Allowed Error, "The requested method POST is not allowed for the URL /confirm.asp." so I'm not sure what else I'm missing in my code.

  • #5
    Supreme Master coder! glenngv's Avatar
    Join Date
    Jun 2002
    Location
    Philippines
    Posts
    11,033
    Thanks
    0
    Thanked 248 Times in 245 Posts
    Your ISP must have disabled POST request. Verify this with your host.

  • #6
    New to the CF scene
    Join Date
    Jun 2007
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Thank you for your feedback, the issue has been resolved, as I can't run ASP scripts on my server, so I've fixed the problem with PHP.

    Thanks for your wealth of information. It's much appreciated.


  •  

    Posting Permissions

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