Form Question
Results 1 to 5 of 5

Thread: Form Question

  1. #1
    Banned
    Join Date
    Apr 2003
    Posts
    51

    Form Question

    What i'm trying to do is have a form with two submit buttons. One will lead to one .php script and clicking the other will lead to another . Does anybody know how to do something like that or similar?

  2. #2
    Junior Member
    Join Date
    Jul 2003
    Posts
    7
    your probably at the wrong place to ask for this but to get this thread out of the unawnsered list. try to rewrite your form.action using javascript, with a button onclick.
    --
    Computers are like humans, except that they dont blame
    their mistakes on other, computers.

  3. #3
    Banned
    Join Date
    Apr 2003
    Posts
    51
    yah, that's probably what i need to do, but a question to that is do i put anything in the action (<form action=? >) or do i just leave the action part out?

  4. #4
    Webius Designerous Indiginous
    Join Date
    Mar 2002
    Location
    South Florida
    Posts
    1,123
    What you need to do is det up 2 forms. IE


    <form action="/cgi/formmail" method="post" enctype="application/x-www-form-urlencoded" target="_self">
    <input name="realname" type="text" id="realname" size="20" maxlength="30">



    E-Mail Address:<input name="email" type="text" size="20" maxlength="40">




    Please provide us with as much information as possible concerning your goals.

    <textarea name="info" cols="50" rows="20"></textarea>


    <input type="submit" name="Submit"
    <input name="Reset" type="reset" id="Reset" value="Reset">
    </form>


    Then do another form....

    <form action="/cgi/formmail" method="post" enctype="application/x-www-form-urlencoded" target="_self">
    <input name="realname" type="text" id="realname" size="20" maxlength="30">



    E-Mail Address:<input name="email" type="text" size="20" maxlength="40">




    Please provide us with as much information as possible concerning your goals.

    <textarea name="info" cols="50" rows="20"></textarea>


    <input type="submit" name="Submit"
    <input name="Reset" type="reset" id="Reset" value="Reset">
    </form>


    With a different action. The action= part will be what the form gets sent to. Most time you will want to send to a php app thru the POST use.

    Ie.. In the php app have

    $realname = $_POST['realname'];

    This will send the realname valu from the form into the php app.

    Let me know if you have any other questions....

    xmaddness

  5. #5
    Banned
    Join Date
    Apr 2003
    Posts
    51
    a'right thanks, that helps ^_^

Posting Permissions

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