Register

If this is your first visit, please click the Sign Up now button to begin the process of creating your account so you can begin posting on our forums! The Sign Up process will only take up about a minute of two of your time.

Page 1 of 2 1 2 LastLast
Results 1 to 10 of 16

Thread: Form submit

  1. #1
    Senior Member joncom11's Avatar
    Join Date
    Oct 2003
    Posts
    284
    Member #
    3532
    Hey... what i want to do is have a page, auto submit some fields apon loading.... i will have a bunch of hidden fields... and i would like it to automatically submit them all automatically.

    also, should i use GET or POST method? what is the difference?
    Pixel Fuse - Signature webpage, just a spashpage.
    Flash Frogger - Frogger remake, animated/coded in Flash (incomplete/discontinued)
    Daase Art Studio - Homepage of David Daase, a Canadian landscape artist - image gallery/showcase.
    More links if I think of some...

  2.  

  3. #2
    Senior Member
    Join Date
    Dec 2003
    Posts
    1,274
    Member #
    4362
    GET passes the information in the URL like this:
    someurl.php?name=John&lastname=Doe&age=99
    POST passes the information in a way that is invisible to the user. When a lot of info is going to be send, use POST. For other tasks (like displaying threads in this forum, look at the url of this page) use GET

  4. #3
    WDF Staff mlseim's Avatar
    Join Date
    Apr 2004
    Location
    Cottage Grove, Minnesota
    Posts
    7,720
    Member #
    5580
    Liked
    718 times
    What server-side language will you be using to accept the form information and do the email? PHP or Perl?

    If you have trouble, give us a link to the web site where you have your form.


  5. #4
    WDF Staff Wired's Avatar
    Join Date
    Apr 2003
    Posts
    7,657
    Member #
    1234
    Liked
    138 times
    Yes, POST. In some big forms I have, I have a confirmation page that passes all of the values with hiddens. User is unwaware of this.
    The Rules
    Was another WDF member's post helpful? Click the like button below the post.

    Admin at houseofhelp.com

  6. #5
    Senior Member
    Join Date
    Dec 2003
    Posts
    1,274
    Member #
    4362
    Quote Originally Posted by Wired
    Yes, POST. In some big forms I have, I have a confirmation page that passes all of the values with hiddens. User is unwaware of this.
    Why? Isn't it easier to simple retrieve each value with $_POST[himama]

  7. #6
    Senior Member joncom11's Avatar
    Join Date
    Oct 2003
    Posts
    284
    Member #
    3532
    thanks for all the replies... but no one has answered my "primary" question yet... i want my page to auto submit the hidden values on page load....
    Pixel Fuse - Signature webpage, just a spashpage.
    Flash Frogger - Frogger remake, animated/coded in Flash (incomplete/discontinued)
    Daase Art Studio - Homepage of David Daase, a Canadian landscape artist - image gallery/showcase.
    More links if I think of some...

  8. #7
    Senior Member
    Join Date
    Dec 2003
    Posts
    1,274
    Member #
    4362
    With PHP:
    just do $_POST['somehiddeninput'] just after the form's HTML code.

  9. #8
    WDF Staff mlseim's Avatar
    Join Date
    Apr 2004
    Location
    Cottage Grove, Minnesota
    Posts
    7,720
    Member #
    5580
    Liked
    718 times
    I still don't quite understand what you're trying to do.

    Where is the "hidden" information going? To a Perl script?
    ... and if the "hidden" information needs to be hidden, why couldn't someone just look at the HTML code and see the hidden script.

    This reminds me of people that use hidden values on shopping carts.

    Try this search:
    http://www.altavista.com/web/results...q&Translate=on

    Where is the security in that?

    Maybe if we know what your intended purpose is, we could answer the question.


  10. #9
    Senior Member
    Join Date
    Dec 2003
    Posts
    1,274
    Member #
    4362
    For what do you want security on that? What's the point of seeing the price of something by a hidden input?

  11. #10
    WDF Staff Wired's Avatar
    Join Date
    Apr 2003
    Posts
    7,657
    Member #
    1234
    Liked
    138 times
    Ok. Do you want the hidden values to be submitted when the cust hits submit or when a page is loaded? Either way, let's say you have some hidden values in a form and someone hits submit, and let's say you're using post. You'd do something like

    PHP Code:
    $variable $_POST['somehiddeninput'];
    // personal preference to assign it to a variable,
    // a bit easier to read 


    From there, you just use it however you want to. If this is not what you want to do, then please explain what you want to do a bit further, possibly with some code if it'll help.
    The Rules
    Was another WDF member's post helpful? Click the like button below the post.

    Admin at houseofhelp.com


Page 1 of 2 1 2 LastLast

Remove Ads

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT -6. The time now is 03:34 AM.
Powered by vBulletin® Version 4.2.3
Copyright © 2019 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: PurevB.com