Go Back   HostGator Peer Support Forums > General Discussion > Webhosting

Notices

Reply
 
Thread Tools
  #1  
Old 02-19-2004, 03:50 PM
mediahosting's Avatar
mediahosting mediahosting is offline
Hatchling Croc
 
Join Date: Feb 2004
Location: Oregon
Posts: 28
Default

Here's the HTML code for the form:

Paste in the body of your HTML script

<table width="125" border="0" cellspacing="0" cellpadding="0">
<tr>
<td> <form action="http://www.yourdomain.com/email.php" method="post" name="login" target="_blank">
<table width="125" border="0" cellspacing="0" cellpadding="5">
<tr>
<td height="14"><font color="#000000" size="2" face="Verdana, Arial, Helvetica, sans-serif">Domain:</font></td>
</tr>
<tr>
<td><input name="domain" type="text" id="domain" value="yourdomain.com" size="15">
</td>
</tr>
<tr>
<td height="22"><input type="submit" name="Submit" value="log in" align="middle">
<br> </td>
</tr>
</table>
</form></td>
</tr>
</table>


Just edit the form action to point to your php file.

Here's the PHP script (Permissions of 644), you need to create a file with extension .php Name it anything you like, but make sure to do the obvious and change your HTML page form action to point to the new file name.


<?
#$domain = "domain.com";
?>
<head>
<title>Log In To Webmail...</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta http-equiv="refresh" content="1;URL=http://<? print "$domain"; ?>:2095">
</head>
<body>
<p><b>Hi <? echo $domain ?>!</b></p>
<p><b>Please enter your username & password!</b></p><br><br>
</body>

You can add images inside the body if you like etc.

Here's an example of this script working on Hostgator.com servers

http://www.mediahosting.us/email.html

This form on my site posts to http://www.mediahosting.us/email.php

Let me know what you all think, if it works for you ok etc.

- Kris Parker
Media Hosting

Last edited by mediahosting; 01-03-2005 at 11:57 PM.
Reply With Quote
  #2  
Old 03-19-2004, 08:56 PM
answer answer is offline
Hatchling Croc
 
Join Date: Mar 2004
Posts: 2
Default

awesome! it works. what i did was just copy the html code off the page the first link takes you to when you fill out the domain name. thanks!
Reply With Quote
  #3  
Old 05-06-2004, 01:58 PM
97transam's Avatar
97transam 97transam is offline
Baby Croc
 
Join Date: Apr 2004
Location: Chalfont, Pa
Posts: 52
Default

Really cool!
...and then it got ME thinking. Here's what I did;

1) created a folder /email in the account.
2) Placed a file that must be "index" , i.e. index.php, with your code just modified slightly for refresh to neomail in this file:

[code:1:d43f46f1f2]
&lt;?php
$domain = &quot;www.yourdomain.com&quot;;
$title = &quot;$domain Email&quot;;
?&gt;

&lt;head&gt;
&lt;title&gt;Log In To Webmail...&lt;/title&gt;
&lt;meta http-equiv=&quot;Content-Type&quot; content=&quot;text/html; charset=iso-8859-1&quot;&gt;
&lt;meta http-equiv=&quot;refresh&quot; content=&quot;1;URL=http://&lt;? print &quot;$domain&quot;; ?&gt;:2095/neomail/neomail.pl&quot;&gt;
&lt;/head&gt;
&lt;body&gt;
&lt;br&gt;Welcome to the &lt;? echo $domain ?&gt; email system!
&lt;br&gt;
&lt;br&gt;Please enter your username &amp; password!&lt;br&gt;&lt;br&gt;
&lt;/body&gt;
[/code:1:d43f46f1f2]


This way users on the road only have to remember the following url:
www.yourdomain.com/email

Voila, the "welcome" appears then the login box, then after a correct login, they go straight to their neomail.

--ron
Reply With Quote
  #4  
Old 05-28-2004, 03:01 AM
gameutopia gameutopia is offline
Hatchling Croc
 
Join Date: May 2004
Posts: 17
Default

Nice work!! I've been looking for something like this for weeks without any luck until I stumbled on it here.

Should the .php files be chmod to anything special? or not a big deal since a user needs to enter their user/password anyway.

Thanks again.
GameUtopia
Reply With Quote
  #5  
Old 05-28-2004, 02:31 PM
awibble awibble is offline
Hatchling Croc
 
Join Date: May 2004
Posts: 46
Default

looking at the scripts, i would say that they dont need chmodding to anything special, theave them as is and they should work (just my option, dont take it as the definate answer) .o0(really need to work on that confidence)0o.

-matt
Reply With Quote
  #6  
Old 05-28-2004, 08:09 PM
97transam's Avatar
97transam 97transam is offline
Baby Croc
 
Join Date: Apr 2004
Location: Chalfont, Pa
Posts: 52
Default

Nah, I didn't do any chmodding. I try to keep things simple and not to complicated in case I have to hand off the responsibility. :roll:

..and Matt, you are correct.

catch ya's,

ron
__________________
97 Trans Am
Reply With Quote
  #7  
Old 06-17-2004, 08:40 AM
Angry Amish's Avatar
Angry Amish Angry Amish is offline
Hatchling Croc
 
Join Date: Jan 2004
Location: Washington, PA
Posts: 16
Default

I just used it, and it works smashingly.
__________________
http://www.phantasmo.com
Reply With Quote
  #8  
Old 11-17-2004, 05:53 AM
makhosts makhosts is offline
Hatchling Croc
 
Join Date: Nov 2004
Posts: 14
Question Re: Anyone want a login form to check webmail for there website?

Hi

I've followed all the instructions on this thread and it all seems to work except when the domain name is entered into the box and it forward to the email.php file its not coming up with the username and password box and forward the the URL: http://%3C/?%20print.

please can someone advise what i am doing wrong.

you can check www.makhosts.com to see what im talking about (site is not complete yet tho.)

thanks

Deji
Reply With Quote
  #9  
Old 11-17-2004, 06:18 AM
Stef's Avatar
Stef Stef is offline
Royal Croc
 
Join Date: May 2004
Posts: 715
Default Re: Anyone want a login form to check webmail for there website?

Quote:
Originally Posted by makhosts
I've followed all the instructions on this thread and it all seems to work except when the domain name is entered into the box and it forward to the email.php file its not coming up with the username and password box and forward the the URL: http://%3C/?%20print.
Deji,

check the head section in your email.php. There's a line

<meta http-equiv="refresh" content="1;URL=http://&lt;? print "$domain"; ?&gt;:2095"&gt;

this should be

<meta http-equiv="refresh" content="1;URL=http://<? print "$domain"; ?>:2095">

Stef.
Reply With Quote
  #10  
Old 11-17-2004, 06:47 AM
makhosts makhosts is offline
Hatchling Croc
 
Join Date: Nov 2004
Posts: 14
Default Re: Anyone want a login form to check webmail for there website?

thanks a million Stef, it now work great.

cheers

Deji
Reply With Quote
Reply

Bookmarks

Thread Tools

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

Similar Threads
Thread Thread Starter Forum Replies Last Post
Cpanel login form on index.html page? brian22 Shared Hosting Support 4 03-17-2004 04:23 AM

All times are GMT -5. The time now is 02:43 AM.