Custom 404 Page

  • cancer10
  • Proficient
  • Proficient
  • No Avatar
  • Joined: 29 Jun 2006
  • Posts: 250
  • Status: Offline

Post March 15th, 2008, 11:24 am

Hi,

I am running cPanel 11 with apache.

I want a custom 404 page in php format. Currently its set to 404.shtml by default, even if I change the file name from 404.shtml to 404.php (under cPanel's "Custom Error Pages"), it still redirects to 404.shtml. So I was wondering if there is an alternate trick to do this?


Please guide



Thanx
Interview Questions & Answers - http://www.focusinterview.com
Cheapest Hosting - http://www.igchosting.in
  • Anonymous
  • Bot
  • No Avatar
  • Joined: 25 Feb 2008
  • Posts: ?
  • Loc: Ozzuland
  • Status: Online

Post March 15th, 2008, 11:24 am

  • Don2007
  • Web Master
  • Web Master
  • No Avatar
  • Joined: 21 Nov 2006
  • Posts: 3892
  • Loc: NY
  • Status: Offline

Post March 15th, 2008, 2:55 pm

Replace the 404.shtml with a different 404.shtml
That should do it.
  • cancer10
  • Proficient
  • Proficient
  • No Avatar
  • Joined: 29 Jun 2006
  • Posts: 250
  • Status: Offline

Post March 15th, 2008, 7:28 pm

but I dont need shtml, I need to replace it with php and doing so is not working
Interview Questions & Answers - http://www.focusinterview.com
Cheapest Hosting - http://www.igchosting.in
  • Bogey
  • Disturbed
  • Genius
  • User avatar
  • Joined: 14 Jul 2005
  • Posts: 6642
  • Loc: Ozzuland
  • Status: Offline

Post March 15th, 2008, 7:39 pm

Replace it with another 404.shtml and than resave it as a php. Maybe that is what he meant.
Matthew 7:12 - "Therefore all things whatsoever ye would that men should do to you, do ye even so to them: for this is the law and the prophets."
  • joebert
  • S.T. Manager
  • Genius
  • User avatar
  • Joined: 10 Feb 2004
  • Posts: 11000
  • Loc: Clearwater, FL
  • Status: Offline

Post March 15th, 2008, 8:05 pm

Since you're using Apache you might find it easier to use the ErrorDocument directive in htaccess.
The squeaky wheel gets the grease, but the whining wheel gets replaced.
Picksel: Ubuntu/Gnome alternative to Colorpix
  • cancer10
  • Proficient
  • Proficient
  • No Avatar
  • Joined: 29 Jun 2006
  • Posts: 250
  • Status: Offline

Post March 15th, 2008, 8:32 pm

That solved my problem


Thanx friend
Interview Questions & Answers - http://www.focusinterview.com
Cheapest Hosting - http://www.igchosting.in

Post Information

  • Total Posts in this topic: 6 posts
  • Moderator: Moderator Team
  • Users browsing this forum: No registered users and 30 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
 

© Unmelted Enterprises 1998-2009. Driven by phpBB © 2001-2009 phpBB Group.