form action

Discussion in 'HTML' started by Matt Summers, Dec 30, 2004.

  1. Matt Summers

    Matt Summers Guest

    Hi,

    I have a problem which someone may be able to help me with. I have a html
    page which has a form for users to submit information to a php email script
    and now I want to add a login form. How can this be done? Since having <form
    action="login.php" method="post" target="_top"> and <form action="email.php"
    method="post" target="_top"> confuses the form.

    Thanks in advance,

    Matt
     
    Matt Summers, Dec 30, 2004
    #1
    1. Advertising

  2. Matt Summers

    Oli Filth Guest

    Matt Summers wrote:
    > Hi,
    >
    > I have a problem which someone may be able to help me with. I have a html
    > page which has a form for users to submit information to a php email script
    > and now I want to add a login form. How can this be done? Since having <form
    > action="login.php" method="post" target="_top"> and <form action="email.php"
    > method="post" target="_top"> confuses the form.
    >
    > Thanks in advance,
    >
    > Matt
    >
    >


    There shouldn't be a problem with having multiple forms on the same page.

    Oli
     
    Oli Filth, Dec 30, 2004
    #2
    1. Advertising

  3. Matt Summers

    Matt Summers Guest

    Oli,

    When I click send to send my email I get my login screen.

    Matt

    "Oli Filth" <> wrote in message
    news:Wn_Ad.568$...
    > Matt Summers wrote:
    > > Hi,
    > >
    > > I have a problem which someone may be able to help me with. I have a

    html
    > > page which has a form for users to submit information to a php email

    script
    > > and now I want to add a login form. How can this be done? Since having

    <form
    > > action="login.php" method="post" target="_top"> and <form

    action="email.php"
    > > method="post" target="_top"> confuses the form.
    > >
    > > Thanks in advance,
    > >
    > > Matt
    > >
    > >

    >
    > There shouldn't be a problem with having multiple forms on the same page.
    >
    > Oli
     
    Matt Summers, Dec 30, 2004
    #3
  4. Matt Summers

    Oli Filth Guest

    Matt Summers wrote:
    > Oli,
    >
    > When I click send to send my email I get my login screen.
    >
    > Matt
    >
    > "Oli Filth" <> wrote in message
    > news:Wn_Ad.568$...
    >
    >>There shouldn't be a problem with having multiple forms on the same page.
    >>
    >>Oli

    >


    Do you have a URL for your login/email page that we can take a look at?
     
    Oli Filth, Dec 30, 2004
    #4
  5. In article <xm_Ad.566$>,
    says...
    > Hi,
    >
    > I have a problem which someone may be able to help me with. I have a html
    > page which has a form for users to submit information to a php email script
    > and now I want to add a login form. How can this be done? Since having <form
    > action="login.php" method="post" target="_top"> and <form action="email.php"
    > method="post" target="_top"> confuses the form.


    Have you got two entirely separate forms? Post a URL to your code.

    --
    Hywel http://kibo.org.uk/
    I do not eat quiche.
     
    Hywel Jenkins, Dec 30, 2004
    #5
  6. Matt Summers

    Matt Summers Guest

    www.dorianyates.net/appearances2.html


    "Hywel Jenkins" <> wrote in message
    news:...
    > In article <xm_Ad.566$>,
    > says...
    > > Hi,
    > >
    > > I have a problem which someone may be able to help me with. I have a

    html
    > > page which has a form for users to submit information to a php email

    script
    > > and now I want to add a login form. How can this be done? Since having

    <form
    > > action="login.php" method="post" target="_top"> and <form

    action="email.php"
    > > method="post" target="_top"> confuses the form.

    >
    > Have you got two entirely separate forms? Post a URL to your code.
    >
    > --
    > Hywel http://kibo.org.uk/
    > I do not eat quiche.
     
    Matt Summers, Dec 30, 2004
    #6
  7. Matt Summers

    Oli Filth Guest

    Matt Summers wrote:
    > www.dorianyates.net/appearances2.html
    >
    >
    > "Hywel Jenkins" <> wrote in message
    > news:...
    >
    >>In article <xm_Ad.566$>,
    >>says...
    >>
    >>>Hi,
    >>>
    >>>I have a problem which someone may be able to help me with. I have a

    >
    > html
    >
    >>>page which has a form for users to submit information to a php email

    >
    > script
    >
    >>>and now I want to add a login form. How can this be done? Since having

    >
    > <form
    >
    >>>action="login.php" method="post" target="_top"> and <form

    >
    > action="email.php"
    >
    >>>method="post" target="_top"> confuses the form.

    >>
    >>Have you got two entirely separate forms? Post a URL to your code.
    >>
    >>--
    >>Hywel http://kibo.org.uk/
    >>I do not eat quiche.

    >
    >
    >


    The two forms must be separate; the way you have it, one form is
    contained within the other, which doesn't make sense in HTML.

    You need something like:


    <FORM action="login.php" method="POST">
    .... blah blah blah (controls for login form) ...
    </FORM>

    .... other stuff ...

    <FORM action="email.php" method="POST">
    .... blah blah blah (controls for email form) ...
    </FORM>


    Oli
     
    Oli Filth, Dec 30, 2004
    #7
  8. In article <qQ_Ad.721$>,
    says...
    > "Hywel Jenkins" <> wrote in message
    > news:...
    > > In article <xm_Ad.566$>,
    > > says...
    > > > Hi,
    > > >
    > > > I have a problem which someone may be able to help me with. I have a

    > html
    > > > page which has a form for users to submit information to a php email

    > script
    > > > and now I want to add a login form. How can this be done? Since having

    > <form
    > > > action="login.php" method="post" target="_top"> and <form

    > action="email.php"
    > > > method="post" target="_top"> confuses the form.

    > >
    > > Have you got two entirely separate forms? Post a URL to your code.


    > www.dorianyates.net/appearances2.html
    >
    >

    Your code is screwed. You cannot do this anywhere in a document, let
    alone in the <head>.

    <form action="/dyforum/login.php" method="post" target="_top">
    <form method="post" enctype="multipart/form-data"
    action="/mailform5.php">

    You need to modify either of those scripts so that they either do both
    tasks, or modify login.php so that it POSTs data to mailform5.php if
    log-in is successful.

    http://tinyurl.com/59k6p is your friend.

    --
    Hywel http://kibo.org.uk/
    I do not eat quiche.
     
    Hywel Jenkins, Dec 30, 2004
    #8
  9. Matt Summers

    Matt Summers Guest

    Oli,

    Thanks, I will do that tomorrow.

    Matt

    "Oli Filth" <> wrote in message
    news:YS_Ad.1383$...
    > Matt Summers wrote:
    > > www.dorianyates.net/appearances2.html
    > >
    > >
    > > "Hywel Jenkins" <> wrote in message
    > > news:...
    > >
    > >>In article <xm_Ad.566$>,
    > >>says...
    > >>
    > >>>Hi,
    > >>>
    > >>>I have a problem which someone may be able to help me with. I have a

    > >
    > > html
    > >
    > >>>page which has a form for users to submit information to a php email

    > >
    > > script
    > >
    > >>>and now I want to add a login form. How can this be done? Since having

    > >
    > > <form
    > >
    > >>>action="login.php" method="post" target="_top"> and <form

    > >
    > > action="email.php"
    > >
    > >>>method="post" target="_top"> confuses the form.
    > >>
    > >>Have you got two entirely separate forms? Post a URL to your code.
    > >>
    > >>--
    > >>Hywel http://kibo.org.uk/
    > >>I do not eat quiche.

    > >
    > >
    > >

    >
    > The two forms must be separate; the way you have it, one form is
    > contained within the other, which doesn't make sense in HTML.
    >
    > You need something like:
    >
    >
    > <FORM action="login.php" method="POST">
    > ... blah blah blah (controls for login form) ...
    > </FORM>
    >
    > ... other stuff ...
    >
    > <FORM action="email.php" method="POST">
    > ... blah blah blah (controls for email form) ...
    > </FORM>
    >
    >
    > Oli
     
    Matt Summers, Dec 30, 2004
    #9
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Joe Bloggs
    Replies:
    1
    Views:
    991
    Sudsy
    Aug 3, 2003
  2. rjweytens
    Replies:
    6
    Views:
    16,357
    rjweytens
    Jun 25, 2004
  3. runescience

    Struts mapping action to action???

    runescience, Feb 6, 2006, in forum: Java
    Replies:
    3
    Views:
    1,955
    runescience
    Feb 7, 2006
  4. vyshu
    Replies:
    1
    Views:
    2,704
    Richard Senior
    Apr 27, 2007
  5. John
    Replies:
    0
    Views:
    1,011
Loading...

Share This Page