IPB

Welcome Guest ( Log In | Register )

Using .htaccess To Add Your 404 Error Page, For Apache Web Servers Only
Martyn
post May 8 2007, 09:54 AM
Post #1


WSF Commander
*******

Group: Admin
Posts: 4,662
Joined: 26-August 05
Member No.: 10



SYMPTOMS

Your control panel does not allow you to change the 404 Error to use 404.php

CAUSE

They may use a fixed 404.shtml or the Administrator may have disabled the feature.

SOLUTION

Create a file called .htaccess in your web documents root directory (your installation includes htaccess.txt which can be renamed).

Make sure it includes:-

CODE
ErrorDocument 404 /404.php


For example your .htaccess might look like this:-

CODE
##########################
#Apache Only system file
##########################
#Sets up 404
##########################
ErrorDocument 404 /404.php

##########################
# Remove the # to disable magic quotes
# (This could cause server errors if you
# do not have permission)
##########################
#php_flag magic_quotes_gpc off


You can also check these settings

SYMPTOMS

Although you have setup the Custom Errors for your web server to call 404.php none of the virtual pages, rotator URLs or link tracker URLs are working correctly and may send you to the homepage.

CAUSE

Some server configurations adding superfluous characters to the query string.

SOLUTION

Switch on the 404 Filter

BCP -->Configuration --> General Configuration --> 404 Filter --> Yes

Also check

Also check your .htaccess has not been overwritten or altered in such a way as to invalidate the ErrorDocument entry.
Go to the top of the page
 
+Quote Post
 
Start new topic
Replies
BobMateer
post May 13 2007, 01:54 PM
Post #2


WSF Professional
*****

Group: PM Unlimited
Posts: 927
Joined: 4-May 07
From: Phoenix, AZ
Member No.: 1,089
Exchanges:




Martyn,

This will not work for me. I have my .htaccess set up exactly like this but it does not affect either the magic quotes or the 404 Error page function.
Can this be corrected on the server? I have a virtual dedicated server with root access. If you can tell me where this information is located on the server,
maybe I can delete it there.


--------------------
Bob Mateer

If I've helped you in any way

Go to the top of the page
 
+Quote Post

Posts in this topic


Reply to this topicStart new topic
7 User(s) are reading this topic (7 Guests and 0 Anonymous Users)
0 Members:

 



RSS Lo-Fi Version Time is now: 23rd September 2024 - 03:44 AM