Pretty 404 pages on WordPress
171 words, 1 minutes
Since my Web site was created, it ran various rendering software
; each of
those generated URL that Google sometimes seems to remember. Many of those URL
aren’t relevant nowadays ; although the information may still be there on the
Web site.
Here’s how I deal with the “404: Page not found
” error on WordPress:
- Go to the WordPress administration page and browse to the extensions section ;
- Grab and install the AskApache Google 404 plugin ;
- Activate the plugin and browse to its
settings
section.
I choose to use the askapache-google-404/404.php
file as the “404.php
Template File”.
I also enabled the Track Errors with Google Analytics
option.
Finally, from the HTML Editor
section, I defined a personal rendering ;
mainly to not show every proposed information and to match my theme. I used the
following code:
<div>
<h3>%error_title%</h3>
<div>
<h3>Related Posts</h3>
%related_posts%
<div id="g404ajax">
<div id="sFormDiv">Loading...</div>
<div id="gDiv"></div>
<div id="lDiv"></div>
<div id="rDiv"></div>
<p style="clear:both;"></p>
</div><!--g404ajax-->
</div><!--content-->
</div><!--post-->
</div>
Now, any URL is rendered in a nice manner.
That’s All Folks!