hosted by liquidweb


Go Back   Web Hosting Talk : Web Hosting Main Forums : Hosting Software and Control Panels : Hosting Software and Control Panels Tutorials : Help creating login script directly to cpanel
Reply

Hosting Software and Control Panels Tutorials Tutorials specifically for control panels and other hosting software.
Forum Jump

Help creating login script directly to cpanel

Reply Post New Thread In Hosting Software and Control Panels Tutorials Subscription
 
Send news tip View All Posts Thread Tools Search this Thread Display Modes
  #1  
Old 05-22-2006, 02:36 PM
webhostingtime webhostingtime is offline
Newbie
 
Join Date: Feb 2006
Posts: 10

Help creating login script directly to cpanel


Hi everyone.
I have already got the layout for the login box. when i add code that i've found on other threads, they create their own buttons. I want to be ableto use whats already on my site.

gxhosting.net

the login form on the left currently doesn't do anything, I want it to directly login to cpanel.

here's the code that is currently there, how would I edit it so that it keep exactly the same layout and allow login to cpanel:




<!-- Customer Login -->
<table border="0" cellpadding="0" cellspacing="0" width="210">
<tr><td><img src="images/title_customerlogin.gif" width="210" height="30" alt=""></td></tr>
<tr><td align="center" background="images/login_bg.gif">
<table border="0" cellpadding="0" cellspacing="0" width="180">
<tr><td><img src="images/clear.gif" width="1" height="3" alt=""></td></tr>
<tr>
<td width="60" class="contentblue">Username</td>
<td width="120"><input type="Text" class="text" style="width:100px;"></td>
</tr>
<tr>
<td class="contentblue">Password</td>
<td><input type="Text" class="text" style="width:100px;"></td>
</tr>
<tr><td>&nbsp;</td><td><img src="images/button_submit.gif" width="63" height="17" alt="" vspace="3"></td></tr>
<tr><td>&nbsp;</td><td class="contentblue">Forgot password</td></tr>
</table>
</td></tr>
<tr><td><img src="images/login_bottom.gif" width="210" height="10" alt=""></td></tr>
</table>
<!-- Customer Login -->




Sorry, I had to post it like that. i couldn't see how to post it within another text box as i've seen in other threads.
I would appreciate any help modifying the above code to make it active to login directly to cpanel.

Reply With Quote


Sponsored Links
  #2  
Old 05-23-2006, 11:27 AM
webhostingtime webhostingtime is offline
Newbie
 
Join Date: Feb 2006
Posts: 10
so no one knows how to sort it out

Reply With Quote
  #3  
Old 05-27-2006, 01:58 AM
dna-hosting dna-hosting is offline
New Member
 
Join Date: May 2006
Posts: 2
Code:
 <!-- Customer Login -->
<table border="0" cellpadding="0" cellspacing="0" width="210">
<tr><td><img src="images/title_customerlogin.gif" width="210" height="30" alt=""></td></tr>
<tr><td align="center" background="images/login_bg.gif">
    <table border="0" cellpadding="0" cellspacing="0" width="180">
    <tr><td><img src="images/clear.gif" width="1" height="3" alt=""></td></tr>
    <tr>
    <td width="60" class="contentblue">Username</td>
    <td width="120"><input type="Text" class="text" style="width:100px;"></td>
    </tr>
    <tr>
    <td class="contentblue">Password</td>
    <td><input type="Text" class="text" style="width:100px;"></td>
    </tr>
<tr><td>&nbsp;</td><td><input name="login" value="login" type="image" src="images/button_submit.gif" width="63" height="17" border="0"></td></tr>
    <tr><td>&nbsp;</td><td class="contentblue">Forgot password</td></tr>
    </table>
</td></tr>
<tr><td><img src="images/login_bottom.gif" width="210" height="10" alt=""></td></tr>
</table>
<!-- Customer Login -->
try that
i changed your img tag

Reply With Quote
Sponsored Links
  #4  
Old 05-27-2006, 07:44 PM
webhostingtime webhostingtime is offline
Newbie
 
Join Date: Feb 2006
Posts: 10
hi there, thanks for trying to help, but that still does not login to the cpanel area.

the lgoin address is not anywhere in the code as you have not told me where to put it. maybe that my mistake as I never provide it. but here it is: http://www.gxhosting.net:2082

Thanks once again as you are the only one who replied

Reply With Quote
  #5  
Old 05-27-2006, 11:44 PM
dna-hosting dna-hosting is offline
New Member
 
Join Date: May 2006
Posts: 2
ok change your code for the login to this:

<!-- Customer Login -->
<form action="cplogin.php" method="post">
<table border="0" cellpadding="0" cellspacing="0" width="210">
<tr><td><img src="images/title_customerlogin.gif" width="210" height="30" alt=""></td></tr>
<tr><td align="center" background="images/login_bg.gif">
<table border="0" cellpadding="0" cellspacing="0" width="180">
<tr><td><img src="images/clear.gif" width="1" height="3" alt=""></td></tr>
<tr>
<td width="60" class="contentblue">Username</td>
<td width="120"><input type="Text" class="text" name="user" style="width:100px;"></td>
</tr>
<tr>
<td class="contentblue">Password</td>
<td><input type="password" class="text" name="pass" style="width:100px;"></td>
</tr>
<tr><td>&nbsp;</td><td><input name="login" value="login" type="image" src="images/button_submit.gif" width="63" height="17" alt="" vspace="3" boder="0"></td></tr>
<tr><td>&nbsp;</td><td class="contentblue">Forgot password</td></tr>
</table>
</td></tr>
<tr><td><img src="images/login_bottom.gif" width="210" height="10" alt=""></td></tr>
</table>
<!-- Customer Login -->


and then create a file called cplogin.php with this code:


<html>
<?php

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

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

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


you should be set after that.
I did not make this code I kinda stole/modified it from a previous post on WHT.
Thanks to whoever created it.

PS you might need to add the http www thing to your url, I couldn't do it cause I don't have 5 posts yet so I can't put that in my post, lol

Reply With Quote
  #6  
Old 05-28-2006, 06:54 PM
webhostingtime webhostingtime is offline
Newbie
 
Join Date: Feb 2006
Posts: 10
thanks but didn't work

Reply With Quote
  #7  
Old 05-28-2006, 07:18 PM
Fixago Fixago is offline
Web Hosting Evangelist
 
Join Date: Apr 2006
Posts: 541
How about this...
Code:
<!-- Customer Login -->
<form action="/cpanel/login/" method="POST">
<table border="0" cellpadding="0" cellspacing="0" width="210">
<tr><td><img src="images/title_customerlogin.gif" width="210" height="30" alt=""></td></tr>
<tr><td align="center" background="images/login_bg.gif">
<table border="0" cellpadding="0" cellspacing="0" width="180">
<tr><td><img src="images/clear.gif" width="1" height="3" alt=""></td></tr>
<tr>
<td width="60" class="contentblue">Username</td>
<td width="120"><input type="Text" name="user" class="text" style="width:100px;"></td>
</tr>
<tr>
<td class="contentblue">Password</td>
<td><input type="Text" name="pass" class="text" style="width:100px;"></td>
</tr>
<tr><td>&nbsp;</td><td><input name="Submit" value="login" type="image" src="images/button_submit.gif" width="63" height="17" alt="" vspace="3"></td></tr>
<tr><td>&nbsp;</td><td class="contentblue">Forgot password</td></tr>
</table>
</td></tr>
<tr><td><img src="images/login_bottom.gif" width="210" height="10" alt=""></td></tr>
</table>
<!-- Customer Login -->

Reply With Quote
  #8  
Old 05-28-2006, 07:22 PM
webhostingtime webhostingtime is offline
Newbie
 
Join Date: Feb 2006
Posts: 10
hi mate, thanks for this. it does seem to work, but the login box appears after asking to login. this box seems to go to the actual host i am reselling through

Reply With Quote
  #9  
Old 05-28-2006, 08:47 PM
2uk2 2uk2 is offline
Junior Guru Wannabe
 
Join Date: Mar 2005
Posts: 40
Google is your friend

Try the first result - http://www.hotscripts.com/Detailed/32562.html

Regards
Steven

Reply With Quote
Reply

Related posts from TheWhir.com
Title Type Date Posted
cPanel Releases cPanel, WHM 11.34 with New User Interface Web Hosting News 2012-10-16 13:09:49
cPanel Conference 2012: What's New with cPanel and WHM with Ken Power Web Hosting News 2012-11-12 13:54:56
Web Hosting Control Panel cPanel and WHM Version 11.32 Adds Features, Fixes Web Hosting News 2012-04-08 11:51:35
cPanel Launches Version 11.32 of Control Panel and Web Host Manager Web Hosting News 2012-02-15 12:46:33
Control Panel cPanel Launches New Apache Configuration Script Web Hosting News 2011-12-28 19:41:39


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes
Postbit Selector

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump
Login:
Log in with your username and password
Username:
Password:



Forgot Password?
Advertisement:
Web Hosting News:



 

X

Welcome to WebHostingTalk.com

Create your username to jump into the discussion!

WebHostingTalk.com is the largest, most influentual web hosting community on the Internet. Join us by filling in the form below.


(4 digit year)

Already a member?