Title: Customize page 404
Last modified: August 22, 2016

---

# Customize page 404

 *  Resolved [Marouane87](https://wordpress.org/support/users/marouane87/)
 * (@marouane87)
 * [11 years, 6 months ago](https://wordpress.org/support/topic/customize-page-404/)
 * Hello,
 * I really appreciate the help provided through the many threads I’ve opened 🙂!
   But I still have a question please.
    I want to change the 404 page to show a 
   personalized image and keep the search form, I’ve found the [snippet](http://themesandco.com/snippet/display-slider-404-search-pages/)(
   provided by Nicolas) to add slides, but couldn’t figure out how to change it 
   to show the personalized picture and keep the search form… Here is my “try”…
 *     ```
       add_filter('tc_show_image' , '__return_true' );
       add_filter('tc_image_name_id' , 'set_image_name');
       function set_image_name( $original_name ) {
       if ( ! is_404() && ! is_search() )
       return $original_name;
       return 'image_404.jpeg';//<= write the name of your slider here
       get_search_form( $echo = false );
       }
       ```
   
 * Thank you very much!

Viewing 10 replies - 1 through 10 (of 10 total)

 *  [TheMadWiddler1200](https://wordpress.org/support/users/themadwiddler1200/)
 * (@themadwiddler1200)
 * [11 years, 6 months ago](https://wordpress.org/support/topic/customize-page-404/#post-5564081)
 * I would also like to know how to customize the 404 page.
 *  [Rocco Aliberti](https://wordpress.org/support/users/d4z_c0nf/)
 * (@d4z_c0nf)
 * [11 years, 6 months ago](https://wordpress.org/support/topic/customize-page-404/#post-5564087)
 * mm [@marouane87](https://wordpress.org/support/users/marouane87/) you invented“
   tc_show_image” and “tc_image_name_id” that’s why nothing happens.
    Nicolas’ snippet
   was to show a slider in that page, create a slider and use that snippet. Do you
   want something like: [slider] [missing page alert] [search] ?
 *  Thread Starter [Marouane87](https://wordpress.org/support/users/marouane87/)
 * (@marouane87)
 * [11 years, 6 months ago](https://wordpress.org/support/topic/customize-page-404/#post-5564105)
 * I thought maybe it was the same, my mistake 🙂 !
 * No need for slider, just:
    [missing page alert] (which is the personalized picture)[
   Search]
 * Thank you very much!
 *  [Rocco Aliberti](https://wordpress.org/support/users/d4z_c0nf/)
 * (@d4z_c0nf)
 * [11 years, 6 months ago](https://wordpress.org/support/topic/customize-page-404/#post-5564118)
 * Try this then,
 *     ```
       add_filter('tc_404_content', 'my_404_content');
       function my_404_content(){
           $image_url = 'REPLACE THIS WITH YOUR IMAGE URL';
           return sprintf('<img alt="Not Found" class="404-img" src="%1s">%2$s',
               $image_url,
               get_search_form( $echo=false)
           );
       }
       ```
   
 *  Thread Starter [Marouane87](https://wordpress.org/support/users/marouane87/)
 * (@marouane87)
 * [11 years, 6 months ago](https://wordpress.org/support/topic/customize-page-404/#post-5564125)
 * Thank you very much! One final request please, is it possible to display the 
   same when a search request has no result?
 * Thank you again 🙂 !
 *  [Rocco Aliberti](https://wordpress.org/support/users/d4z_c0nf/)
 * (@d4z_c0nf)
 * [11 years, 6 months ago](https://wordpress.org/support/topic/customize-page-404/#post-5564129)
 * You’re welcome.
    Just add also this to your child-theme functions.php
 *     ```
       add_filter('tc_no_result_content', 'my_404_content');
       ```
   
 * This will point to the same function my_404_content.
 *  Thread Starter [Marouane87](https://wordpress.org/support/users/marouane87/)
 * (@marouane87)
 * [11 years, 6 months ago](https://wordpress.org/support/topic/customize-page-404/#post-5564130)
 * Thank you very much!
 * In case someone wants to delete “No Search Results for : nothing” and the glass
   icone (like me), just add
 *     ```
       add_filter('tc_search_results_header_content', 'my_no_result');
       function my_no_result(){
           return;
       ```
   
 * (Yes, I’m learning to write small functions 😀 !)
 *  [Rocco Aliberti](https://wordpress.org/support/users/d4z_c0nf/)
 * (@d4z_c0nf)
 * [11 years, 6 months ago](https://wordpress.org/support/topic/customize-page-404/#post-5564133)
 * Oh great you took a look at the hooks api 😀
    ( You’re on the right track… so
   don’t delude me 😛 )
 * Unfortunately the hook tc_no_results_content_icon, as the name suggests, is about
   an icon you already don’t display because we get rid of the original content 
   with the code I posted above.
    You’re interested about some Headings filters 
   like:
 *     ```
       add_filter('tc_search_results_header_content', 'change_search_title');
       function change_search_title($header){
           /* with this if you change the search title when there are no results */
           if ( is_search() && ! have_posts() ){
              $new_title= '<h1>My New No result title</h1>';
              return preg_replace('|<h1.*?</h1>|', $new_title,$header);
           }
           return $header;
       }
       ```
   
 *  [Rocco Aliberti](https://wordpress.org/support/users/d4z_c0nf/)
 * (@d4z_c0nf)
 * [11 years, 6 months ago](https://wordpress.org/support/topic/customize-page-404/#post-5564136)
 * Hey, you edited that message a bunch of time, making my reply useless 😀
    I’m
   glad you’re learning 😀
 *  Thread Starter [Marouane87](https://wordpress.org/support/users/marouane87/)
 * (@marouane87)
 * [11 years, 6 months ago](https://wordpress.org/support/topic/customize-page-404/#post-5564150)
 * I’m sorry about that, I was trying after I posted the question, so I updated 
   my last message depending on my progress 🙂 !

Viewing 10 replies - 1 through 10 (of 10 total)

The topic ‘Customize page 404’ is closed to new replies.

 * ![](https://i0.wp.com/themes.svn.wordpress.org/customizr/4.4.24/screenshot.png)
 * Customizr
 * [Support Threads](https://wordpress.org/support/theme/customizr/)
 * [Active Topics](https://wordpress.org/support/theme/customizr/active/)
 * [Unresolved Topics](https://wordpress.org/support/theme/customizr/unresolved/)
 * [Reviews](https://wordpress.org/support/theme/customizr/reviews/)

## Tags

 * [d4zlook](https://wordpress.org/support/topic-tag/d4zlook/)

 * 10 replies
 * 3 participants
 * Last reply from: [Marouane87](https://wordpress.org/support/users/marouane87/)
 * Last activity: [11 years, 6 months ago](https://wordpress.org/support/topic/customize-page-404/#post-5564150)
 * Status: resolved