Customizing Thesis Theme 404 Error Page

by beyluen on February 10, 2009

in WordPress

Customize Thesis Theme 404 Error Page

Custom 404 error page is your only chance to turn a lost visitor into a reader of your blog. Thesis Theme has a special function to handle 404 error page. It’s a semi-custom page as it does keep with your theme and design, but it only show “You 404′d it. Gnarly, dude.” to your visitors. You may want to change the wording a little bit to show your own personality and suitable for your brand image.

What Is 404 Error?

The 404 or page not found error message is an HTTP standard response code indicating that the page requested by client was not found in the server. It simply means the page you’re requesting does not exist.

In the following post, I’m going to show you how to customize your Thesis Theme 404 error page:

#1: Open custom_functions.php

Open custom_functions.php file using any text editor of your choice. The file is located at thesiscustom folder. This file is purposely for you to customize Thesis Theme without touching the core file.

#2 Adding 404 Error Page Title Action Hook

Add the following codes just below <?php in the file. The remove_action is removing the original 404 error page title while add_action is adding your own custom 404 error page title.

remove_action(’thesis_hook_404_title’, ’thesis_404_title’);
add_action(’thesis_hook_404_title’, ’custom_thesis_404_title’);

#3 Creating 404 Error Page Title Function

The following code should be added to the custom_functions.php file just below add_action code shown in step 2. The function simply prints out the 404 error page title in your browser.

function custom_thesis_404_title() {
?>
PUT YOUR 404 ERROR PAGE TITLE HERE
<?
}

#4 Adding 404 Error Page Content Action Hook

Add the following codes just below the code in step 3. The remove_action is removing the original 404 error page content while add_action is adding your own custom 404 error page content.

remove_action(’thesis_hook_404_content’, ’thesis_404_content’);
add_action(’thesis_hook_404_content’, ’custom_thesis_404_content’);

#5 Creating 404 Error Page Content Function

The following code should be added to the custom_functions.php file just below add_action code shown in step 4. This is the main function where you can customize your add in your own wording for 404 error page in Thesis Theme.

function custom_thesis_404_content() {
?>
 <p>ADD YOUR OWN 404 ERROR PAGE WORDING HERE</p>
<?
}

#6 Result

Finally you can upload custom_functions.php to your web server. And you can see the result by simply enter an invalid URL of your blog.

Conclusion

Try to be creative to turn lost visitors to your blog readers. It’s easy to cutomize 404 error page in Thesis Theme. And really, I love Thesis Theme so much.

Related Posts:

  1. Simple Way To Customize Copyright Footer In Thesis Theme
  2. How To Add Logo In Thesis Theme Header
  3. Best Way To Remove Footer Link In Thesis Theme
  4. How To Add Custom Background Image In Thesis Theme?
  5. How To Change Background Color In Thesis Theme?

If you enjoyed this post, I would be very grateful if you leave a quick comment below or subscribe via email or RSS or follow me on Twitter. Don't miss out on new blogging tips and online business tips! - Bey Luen

{ 10 comments… read them below or add one }

1 Jhangora February 19, 2009 at 3:02 pm

Thanx a lot for the useful info. I am new to blogging and learning the basics. Keep up the good work.

Reply

2 Bey Luen February 19, 2009 at 9:20 pm

@Jhangora,
Thanks for your comment. If you’re interested in reading some topics, feel free to contact me.

Reply

3 haceBeloate May 20, 2009 at 10:59 pm

Hello.
I have been searching for this information and finally found it. Thanks!

Reply

4 Neerav June 13, 2009 at 10:44 am

Thanks for that step by step tutorial :)

I love how thesis lets ppl store all the code customisations in custom_functions.php because it makes Theme & Wordpress updates so much smoother

Reply

5 wordpress review plugin September 4, 2009 at 3:21 pm

The custom_functions.php file gives so much flexibility to the entire thesis, thanks a lot ofr the brilliant tip.

Reply

6 Jonathan October 7, 2009 at 10:03 pm

Hi! Thanks for the tutorial.

I’m no php wizzard, could you tell me what i’m doing wrong?

This is my custom_funtions.php

PUT YOUR 404 ERROR PAGE TITLE HERE

ADD YOUR OWN 404 ERROR PAGE WORDING HERE
<?
}

When uploaded, it doesn’t work at all.
Thanks in advance.

Reply

7 Jonathan October 7, 2009 at 10:05 pm

I see that I incorrectly used the tag?

Could you send me an email to jplijnaer@gmail.com instead. Thanks!

Reply

8 Pol24 October 23, 2009 at 7:14 pm

Beyond the basics, literacy skills are an anachronism. ,

Reply

9 Rajesh Kanuri @ TechCats November 17, 2009 at 6:44 pm

thanks for the tutorial..

Reply

10 Virus and Spyware Removal, Lake Geneva, WI May 2, 2010 at 10:54 pm

Just wanted to say thanks for all of the Thesis posts. You site has become a sort of one-stop-shop for modifying this great framework

Karl A. Krogmann

Reply

Leave a Comment

{ 7 trackbacks }

Previous post:

Next post: