Need help with a login form

Discussion in 'HTML & Website Design' started by AlexPato, Feb 12, 2010.

  1. #1
    Hi People,

    I need some help regarding login form.I have a login form from which i want users to select where they want to login like if from one login form they can choose if they want to login as subscriber or as a writer.

    Thanks
     
    AlexPato, Feb 12, 2010 IP
  2. harrierdh

    harrierdh Peon

    Messages:
    46
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #2
    AlexPato,
    You didn't post any code or a link to the page. What is it specifically you need?
     
    harrierdh, Feb 12, 2010 IP
  3. AlexPato

    AlexPato Peon

    Messages:
    105
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Hey,

    I mentioned everything in the last post i'll give u the code now :

    <form method="post" action="1stfile.php">
    
    <input type="hidden" name="action" value="user_login">
    <table border="0" width="200" cellspacing="0" cellpadding="4" class="common_table">
    <tr><td align="center" colspan="2" class="common_table_top_cell">Log In</td></tr>
    <tr>
    <td align="left" class="cell_embosed2">Username </td>
    <td align="left" class="cell_embosed2"><INPUT class="field10" maxLength="15" size="15" name="username" value=""></td>
    </tr>
    <tr>
    <td align="left" class="cell_embosed2">Password </td>
    <td align="left" class="cell_embosed2"><INPUT class="field10" type="password" maxLength="15" size="15" name="password" value=""></td>
    </tr>
    <tr>
    <td align="left" nowrap class="cell_embosed2">Remember me </td>
    
    <td align="left" class="cell_embosed2"><input type="checkbox" value="1" name="remember_me"></td></tr>
    
    <tr><td align="center" colSpan="2" class="cell_embosed2"><input type="submit" value="Submit" name="B1" class="button10"></td></tr>
    </table>
    </form>
    
    
    Code (markup):

    <form method="post" action="2ndfile.php">
    
    <input type="hidden" name="action" value="user_login">
    <table border="0" width="200" cellspacing="0" cellpadding="4" class="common_table">
    <tr><td align="center" colspan="2" class="common_table_top_cell">Log In</td></tr>
    <tr>
    <td align="left" class="cell_embosed2">Username </td>
    <td align="left" class="cell_embosed2"><INPUT class="field10" maxLength="15" size="15" name="username" value=""></td>
    </tr>
    <tr>
    <td align="left" class="cell_embosed2">Password </td>
    <td align="left" class="cell_embosed2"><INPUT class="field10" type="password" maxLength="15" size="15" name="password" value=""></td>
    </tr>
    <tr>
    <td align="left" nowrap class="cell_embosed2">Remember me </td>
    
    <td align="left" class="cell_embosed2"><input type="checkbox" value="1" name="remember_me"></td></tr>
    
    <tr><td align="center" colSpan="2" class="cell_embosed2"><input type="submit" value="Submit" name="B1" class="button10"></td></tr>
    </table>
    </form>
    
    
    Code (markup):

    These are the codes of two login form now i want like I have one login form and people can choose from a dropdown menu or checkbox that if they want to login as subscriber or writer.
     
    AlexPato, Feb 12, 2010 IP
  4. franzbiely

    franzbiely Peon

    Messages:
    59
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #4
    wow, nice thread
     
    franzbiely, Feb 12, 2010 IP
  5. harrierdh

    harrierdh Peon

    Messages:
    46
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #5
    Couldn't you just put a drop down or a couple radio buttons?
     
    harrierdh, Feb 12, 2010 IP
  6. nadiralishah_webexpert

    nadiralishah_webexpert Guest

    Messages:
    229
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #6
    the easiest way is to use radio buttons, below is an example code for you to add in ur form;

    <input type="radio" name="loginas" value="subscriber">Subscriber <input type="radio" name="loginas" value="writer">Writer
    Code (markup):
     
    nadiralishah_webexpert, Feb 12, 2010 IP