Custom 404 page in joomla

How to set the custom 404 page in joomla?
Change default “Joomla 404 component not found” page

Ans :
Create 404.shtml file under the document root then open the error.php file
vi   /home/username/public_html/templates/system/error.php
then add the following code below the line  “defined( ‘_JEXEC’ ) or die( ‘Restricted access’ );”
if (($this->error->code) == '404') {
echo file_get_contents('');

And then add the following code at the end of error.php file


4 Thoughts to “Custom 404 page in joomla”

  1. When i visit a blog, chances are that i get disappointed.On the other hand,I have to say that you have done a good job here.

  2. Nice site, nice and easy on the eyes and great content too.

  3. Deepika

    One of the best blog I have ever seen with all useful contents..

    1. Hello Deepika,
      Thanks for comments and keep in contact.

Leave a Comment