View Full Version : cPanel login failurl

03-31-2008, 09:08 PM

I am trying to create a webmail login page other than using the cpanel domain.com/webmail. I have the following code below (domain.com/maillogin.php) that works if you enter a correct user/pass. If an incorrect user/pass is entered I get automatically take to domain.com:2095/webmail. Is there a way to be redirected back to domain.com/maillogin.php if an incorrect user/pass is entered


$protocol = 'http';
$port = 2095;


<b>cPanel Login</b><br>
if ($_GET['failed'] == "1") {
echo "Your login attempt failed!";
echo "<form action=\"" . $protocol . "://";
echo $_SERVER['HTTP_HOST'] . ":" . $port . "/login/\" ";
echo "method=POST>";
User: <input type=text name=user><br>
Pass: <input type=password name=pass><br>
echo "<input type=hidden name=failurl value=\"http://" ;
echo "?failed=1\">";
<input type=submit value=Login>


EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum