• GoDaddy Community
  • Websites + Marketing | Website Builders
  • Websites + Marketing | Website Builders

    cancel
    Showing results for 
    Show  only  | Search instead for 
    Did you mean: 
    New

    .htaccess help

    I've got what should be a simple question.  I have a subdomain set up on my hosting account (http://5.kirindesigns.com) and I'm trying to create a custom error document using .htaccess.

     

    I have my .htaccess set up as 

     

    ErrorDocument 404 /redirect.php

    However when I attempt to generate a 404 error with just a random URL (http://5.kirindesigns.com/45B3da) I get an error 500

     

    Internal Server Error

    The server encountered an internal error or misconfiguration and was unable to complete your request.

    Please contact the server administrator at webmaster@5.kirindesigns.com to inform them of the time this error occurred, and the actions you performed just before this error.

    More information about this error may be available in the server error log.

    Additionally, a 500 Internal Server Error error was encountered while trying to use an ErrorDocument to handle the request.

     

    What could I be doing wrong?  Many thanks in advance for all of your help!

    3 REPLIES 3
    Helper I

    Re: .htaccess help

    Hi

     

    Try this way "ErrorDocument 404 /redirect.htm" or "ErrorDocument 404 /redirect.html", and change the name as 404.html for easier to type. i am not sure it will work on GoDaddy.

     

    Alex Lits
    New

    Re: .htaccess help

    Thanks for the reply, however the error document needs to be PHP and the name of the file doesn't matter.  The .htaccess file is clearly attempting to use it but giving an error 500.

     

    I have a Linux hosting account, there should be no issue with custom error documents via .htaccess, it's a common practice.

    Helper I

    Re: .htaccess help

    Ok. I see what you mean. It’s depends on the system that works. 

    Alex Lits