SitePoint Sponsor

User Tag List

Results 1 to 6 of 6
  1. #1
    SitePoint Enthusiast
    Join Date
    Aug 2001
    Posts
    26
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    ColdFusion? Help....

    I am trying to foward a form to another sheet after the user checks a checkbox and inputs their email address. To get a better I idea of what I am doing go to this link.

    www.mavpac.com/MFG/mfgresults.cfm

    I do understand that in the page that will foward the form I will be using <cfform> tag and on the page that will be receiving the form I will use a <cfoutput> tag. I just don't quite understand the concept of sending the data in the form to the second page. Can somebody please help me.

    Now this allowed me to pass the email which is in a text box and the check box to the next page. But I am lost after that.
    <cfoutput>
    <cfform action="test3.cfm" name="form1" method="post">
    <input type="checkbox" name="checkbox" value="checkbox" checked>
    <p>
    <input type="text" name="email" value="my@email.com">
    <input type="submit" name="Submit" value="Get Quote">
    </p>
    </cfform>
    </cfoutput>

    Derek

  2. #2
    SitePoint Guru
    Join Date
    Sep 1999
    Location
    Singapore
    Posts
    854
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Basically forms forwards information by either POST or GET.

    When you GET, the form data will be encoded as part of the URL in the form of query strings, like so:

    If you POST it, which is what you are doing, then the form data is sent as part of the HTTP request.

    HTH.

  3. #3
    SitePoint Enthusiast
    Join Date
    Aug 2001
    Posts
    26
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Confused on Coldfusion

    Any suggestions on how I can post that form to another page and see the information they requested?

  4. #4
    Yugo full of anvils bronze trophy hillsy's Avatar
    Join Date
    May 2001
    Location
    :noitacoL
    Posts
    1,859
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I don't use the <cfform> tag, so this could be wrong, but...

    You should be able to access values submitted in the form by using a variable like #form.fieldname# on your receiving page.

    <edit: e.g. '#form.email#'>

    Is this what you're trying to do?
    Last edited by hillsy; Aug 1, 2001 at 16:14.
    that's me!
    Now A Pom. And a Plone Nut
    Broccoli Martinez Airpark

  5. #5
    SitePoint Enthusiast
    Join Date
    Aug 2001
    Posts
    26
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Still confused

    I am trying to pass information from a query on page one. So the #form.fieldname# does not work. I am new to coldfusion so I can't tell you why I just know it does not work.

    Any suggestions will be greatly appreciated....


    Derek

  6. #6
    Yugo full of anvils bronze trophy hillsy's Avatar
    Join Date
    May 2001
    Location
    :noitacoL
    Posts
    1,859
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I don't understand why you would need to use a query on page one

    A bit more detail would be helpful. Do you know anything other than "it doesn't work"? What error message are you getting? Can you post the source for your form and its target page?

    I can confirm that the #FORM.value# syntax works fine for vanilla HTML forms (which is all I ever use). Perhaps it's a <cfform> thing.

    For example, if you were using <form> tags, you would be able to access the user's email address using #FORM.email#
    that's me!
    Now A Pom. And a Plone Nut
    Broccoli Martinez Airpark


Bookmarks

Posting Permissions

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