The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

webmail

Discussion in 'E-mail Discussions' started by terrence, Dec 12, 2004.

  1. terrence

    terrence Registered

    Joined:
    Dec 8, 2004
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    Dear all,
    my website is running on webpage with html instead php. I have try add the webmail at the corner of my website with the code below:
    <form action="http://domain.com:2095"
    method=POST>
    User: <input type=text name=user><br>
    Pass: <input type=password name=pass><br>

    <input type=submit value=Login>
    </form><br>

    But when i key in and press login... it will pop up the menu to require username and password again. how can i fix that? thank you
     
  2. linux-image

    linux-image Well-Known Member

    Joined:
    Jun 8, 2004
    Messages:
    1,192
    Likes Received:
    1
    Trophy Points:
    38
    Location:
    India
    cPanel Access Level:
    Root Administrator
    http://domain.com:2095 always calls a popup window else you will need to pass the username and password as agruments via the GET/POST command.. iam not sure of this process; but all i can say is it is very insecure.
     
  3. dalem

    dalem Well-Known Member
    PartnerNOC

    Joined:
    Oct 24, 2003
    Messages:
    2,577
    Likes Received:
    40
    Trophy Points:
    48
    Location:
    SLC
    cPanel Access Level:
    DataCenter Provider
    use this

    ---------------cplogin.php----------
    <html>
    <?php

    #your domain or ip
    $domain = "yourdomain.com";

    if(!$_POST['login']) {
    exit;
    }

    $user = $_POST['user'];
    $pass = $_POST['pass'];
    $port = $_POST['port'];

    $port == "2083" || $port == "2096" ? $pre = "https://" : $pre = "http://";
    $port == "2095" || $port == "2096"

    ?>
    <body onLoad="setTimeout('document.forms[0].submit();',10)">
    <form action="<?php echo "".$pre."".$domain.":".$port."/login/"; ?>" method="post">
    <input type="hidden" name="user" value="<?php echo $user; ?>">
    <input type="hidden" name="pass" value="<?php echo $pass; ?>">
    </form>
    </body>
    </html>
    ------------------------------------------------------------------

    -------------webmail form--------------------------------------

    <form action="cplogin.php" method="post">
    <table cellspacing="4" cellpadding="0">
    <tr><td>Username:</td><td><input type="text" name="user"></td></tr>
    <tr><td>Password:</td><td><input type="password" name="pass"></td></tr>
    <tr><td>Login To:</td>
    <td align="right">
    <select name="port">
    <option value="2095">Webmail</option>
    <option value="2096">Secure Webmail</option>
    </select>
    </td></tr>
    <tr><td align="right" colspan="2">
    <input type="submit" name="login" value="login" style="cursor:pointer">
    </td>
    </tr>
    </table>
    </form>
    ---------------------------------------------------------------------------------
     
    #3 dalem, Dec 12, 2004
    Last edited: Dec 12, 2004
  4. neel

    neel Member

    Joined:
    Jan 6, 2005
    Messages:
    5
    Likes Received:
    0
    Trophy Points:
    1
    don't want to use full email address

    hi can u help me by telling how can I make an interface through which i need not to write the full email address. I found a jscript but it is not working. Will someone pls help?? :)
     
  5. autumnwalker

    autumnwalker Member

    Joined:
    Jan 5, 2005
    Messages:
    17
    Likes Received:
    0
    Trophy Points:
    1
    jus put value="@mydomain.com" in the username field
    Code:
    <input type="text" name="user" value="@mydomain.com">
     
Loading...

Share This Page