View Full Version : editing error pages
pghcollectibles
04-18-2008, 10:22 AM
i decided to further customize my page i kight as well customize my error page only my code in /public_html/support/404.shtml looks like this:
<html><head><title>404 Not Found</title></head>
<body bgcolor=white>
<h1>404 Not Found</h1>
The requested URL <!--#echo var="REQUEST_URI" --> does not exist.
</body></html>
but the actual page looks like this:
Not Found
The requested URL /dog.html was not found on this server.
Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.
Apache/2.2.8 (Unix) mod_ssl/2.2.8 OpenSSL/0.9.8g DAV/2 mod_auth_passthrough/2.1 mod_bwlimited/1.4 FrontPage/5.0.2.2635 Server at www.pghcollectibles.com Port 80
so where does the apache stuff come from and can i get rid of it?
Ealasaid
04-18-2008, 11:17 AM
Does this help?
http://hostmonsterforums.com/showthread.php?t=3165&highlight=error+pages
http://hostmonsterforums.com/showthread.php?t=2915&highlight=error+pages
pghcollectibles
04-19-2008, 10:32 AM
i think the second thing you mentioned might get me where i want even though it is not exactly what i asked and the first thing you mentioned only leads me to what tmoney said in the first thread and what sjlplat said in the second thread you mentioned which is not what i asked was it. did you even read my post or do you just not understand what i was asking.
---in the first example you gave me, tmoney mentioned the files are in my stuff somewhere.
---i found them (i think) in the place i mentioned when i started this thread.
---i asked: "where does the apache stuff come from" meaning this:
"Not Found
The requested URL /dog.html was not found on this server.
Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.
Apache/2.2.8 (Unix) mod_ssl/2.2.8 OpenSSL/0.9.8g DAV/2 mod_auth_passthrough/2.1 mod_bwlimited/1.4 FrontPage/5.0.2.2635 Server at www.pghcollectibles.com (http://www.pghcollectibles.com/) Port 80"
---and basically i said this doesnt look right "/public_html/support/404.shtml"
so without using "redirection" with htaccess (which i will do if necessary) where are the actual files that are in my folders somewhere or the location of the file whose html code appears to look like this:
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>404 Not Found</title>
</head><body>
<h1>Not Found</h1>
<p>The requested URL /dog.html was not found on this server.</p>
<p>Additionally, a 404 Not Found
error was encountered while trying to use an ErrorDocument to handle the request.</p>
<hr>
<address>Apache/2.2.8 (Unix) mod_ssl/2.2.8 OpenSSL/0.9.8g DAV/2 mod_auth_passthrough/2.1 mod_bwlimited/1.4 FrontPage/5.0.2.2635 Server at www.pghcollectibles.com Port 80</address>
</body></html>
shadmego
04-19-2008, 10:02 PM
Let's try to be more mindful of the fact that tone cannot be inferred in online conversations. The above post seems a rather harsh reply to an innocent attempt at answering a question.
The second link above is just an example of how you can manage your error pages.
Another way, as mentioned by Hostmonster can be seen in the following link:
http://helpdesk.hostmonster.com/kb/index.php?x=&mod_id=2&id=373
If you are asking where the variables are stored, I would imagine they are server wide, and users cannot modify what the text is for each variable. If you don't want the variable in there, simply delete the echo statement and insert your own text in the error page.
The actual error pages, in my account, are located in the main directory (public_html). I can edit them using File Manager, or the Error Pages link in my CPanel home page, as discussed by the link I provided.
~regards
pghcollectibles
04-20-2008, 05:38 AM
alright i am going to run some code to log ips and uris and maybe some banning stuff if too many 403 are encountered. so i dont want the shtml. im going to want php so i will work with the htaccess to redirect. thanks for the input all.
sorry about that ealasaid
i wanted to know where the code was coming from and i still dont know
Kelly Jones
09-09-2008, 01:32 AM
I created custom error code pages (400.shtml to 500.shtml) to replace the default, using cPanel's Advanced/Error Pages option.
They are well-designed, clear, and informative.
Now Google trips in after about 5 seconds, with its own generic error code page. It is definitely not as helpful as the ones I created.
Is there some way that I can prevent the Google robot from replacing my pages?
Thanks in advance for all helpful advice,
Kelly Jones
Kelly Jones
09-17-2008, 12:32 AM
Problem solved: I discovered it wasn't Google but the Freecorder toolbar added to my browser. It was automatically "fixing" error code pages. Instructions for disabling this function are listed on the replacement error code page provided by Freecorder.
pghcollectibles
11-16-2008, 08:15 PM
wow i found the answer, well at least i know what it is i just dont know where it is. i ran phpinfo() and i found this as an environment variable:
SERVER_SIGNATURE <address>Apache/2.2.9 (Unix) mod_ssl/2.2.9 OpenSSL/0.9.8i DAV/2 mod_auth_passthrough/2.1 mod_bwlimited/1.4 FrontPage/5.0.2.2635 Server at reference.pghcollectibles.com Port 80</address>
so there is:
SERVER_SIGNATURE
_SERVER["SERVER_SIGNATURE"]
_ENV["SERVER_SIGNATURE"]
i have looked in php.ini and it is not there. where does that get set? i know there are people here who know this stuff so... lay it on me.
also, along those same lines... does anyone know where the file is that creates the code for following:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<html>
<head>
<title>Index of /tests/afolder</title>
</head>
<body>
<h1>Index of /tests/afolder</h1>
<ul><li><a href="/tests/"> Parent Directory</a></li>
<li><a href="1.php"> 1.php</a></li>
<li><a href="2.php"> 2.php</a></li>
<li><a href="3.php"> 3.php</a></li>
</ul>
<address>Apache/2.2.9 (Unix) mod_ssl/2.2.9 OpenSSL/0.9.8i DAV/2 mod_auth_passthrough/2.1 mod_bwlimited/1.4 FrontPage/5.0.2.2635 Server at reference.pghcollectibles.com Port 80</address>
</body></html>
that is what you would see if you had a folder named afolder in a folder named tests with no index page in it. and naturally it is finished with the SERVER_SIGNATURE
Powered by vBulletin™ Version 4.0.5 Copyright © 2010 vBulletin Solutions, Inc. All rights reserved.