Jump to content

Recommended Posts

Posted

On one of my sites I am not using a custom 404 page so in the meanwhile I get the standard "Not Found" page. In MSIE I think that page is served by the browser itself (the less than 10k rule). In Netscape I'm not sure. Netscape also includes the name of the URL being sought.

 

eg: Not Found

The requested URL /ty.htm was not found on this server.

 

My question: is there a way to show the url not found as part of the content of a 404 page?

 

The answer is probably really obvious but I'm just not seeing it! Been looking and looking for related info but I can't find anything.

 

Ok, stop laffing :P

 

-Ty

Posted

No, unfortunately it does not. It only shows the location of the error document itself. I also tried with DOCUMENT_NAME and DOCUMENT_URI and they produced a negative result as well.

 

Thanks though Andy, I appreciate it.

 

-Ty

Posted

Odd, seems to work on my site.

 

try typing "www.mycoted.com" and then "/garbage/more_garbage"

 

or some such thing and see if my error page comes up with the effect you are after.

 

Andy

Posted

Maybe I am reading this wrong. You are using the custom 404 in CPanel right? Isnt there a button at the top that says Requested URL? cant you just click in your code where you want it to be and select that button? Put this in your browser knifeandblade.com/azfdssaf.html

 

Is that what you are referring to?

Posted

Thanks guys. Andy - tried yours - worked fine on your site. Rob - I didn't see your post till after I messed with mine some but no, I wasn't doing the custom page through Cpanel. I already had the page in public_html and put the appropriate line in the htaccess file :

 

ErrorDocument 404 /404.html

 

But it didn't work. So I pasted the page into the Cpanel template and it works just fine. I find that very odd but I sure won't complain :P

 

 

Thanks,

-Ty

Posted

Hi,

 

I edited my htaccess to point to my own folder with loads of error pages in them. One thing you must remember is that SSI and includes do not work with error pages, they must be flat html pages

 

Jim

Posted

Although not part of the issue I was having that's good to know. In the past I have always edited htaccess for error messages and I'm still getting used to a lot of functions here :D

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...