Got 2 forms and want to merge them? Desperate for help:(

Discussion in 'PHP' started by Ernster, Aug 23, 2007.

  1. #1
    I got 2 forms that submit data to 2 different databases

    I want to merge the forms into 1 but still work seperately.

    So 1 submit button but 2 different form methods, for example:

    <form method="post" action="http://www.url1.com>
    <form method="post" action="http://www.url2.com>

    However, both forms have name and email fields, but I want JUST 1 name and email field but I want the data to submit to the 2 seperate databases.

    So how can I do this, and what would I type. Im a PHP newbie.

    Please helpe me, thanks
     
    Ernster, Aug 23, 2007 IP
  2. bibel

    bibel Active Member

    Messages:
    289
    Likes Received:
    6
    Best Answers:
    0
    Trophy Points:
    58
    #2
    bibel, Aug 23, 2007 IP
  3. Ernster

    Ernster Peon

    Messages:
    535
    Likes Received:
    38
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Thanks bibel but I'm lost lol so confused how to write this. Surely it would be better to just keep it all PHP?

    Can anyone help me:(
     
    Ernster, Aug 24, 2007 IP
  4. daboss

    daboss Guest

    Messages:
    2,249
    Likes Received:
    151
    Best Answers:
    0
    Trophy Points:
    0
    #4
    why not simply merge both forms into 1 and then post the data to a new php page which will sort out which data goes into which database. once that is done, redirect to the page that you want the visitor to see after submission of the form data.
     
    daboss, Aug 24, 2007 IP