×
Please Join Softare On Facebook

Don't Forget To Join With Our Community

Enter Your Email Address :-

Please Check Your Email Inbox For Complete Subscription

Keywords

3D Logo Text Mockup Antivirus Apple iOS7 app Icons Backgrounds BisListe Blank t-shirt template Blog Templates Blog Tricks bluestack Brushes business doodles Business Website Template cache cache plus Chrome Chrome Layouts CodeCanyon compress your jpg images Corporate Branding Mockup Dashboard UI Elemets Deals Design Articles Design Bundles Design Inspiration Domain Easter Eggs eCommerce Flat UI Kit Elegant Themes Facebook facebook like all Firefox Fonts Free Photos Free PSD Files Free Stuff Free Wordpress Theme freebies Giveaway Google Google Chrome Themes Graphics Graphics Icons Hosting how to see google cache version webpage HTML Template icons Icons Design Infographic Elements iPhone 5C Mockup iPhone 7 Concept JPEGmini Latest Updates Layouts Light Music UI Elements logos Magento and Opencart Theme Magnifying Glass Miscellaneous Mockup PSD Mockup template parallax Patterns Photoshop Actions Photoshop Gradients Photoshop Patterns Photoshop Resources Photoshop Tutorials PHP PNG Files Premium Blogger Template Premium Wordpress Themes PSD PSD Templates Quotes Responsive Responsive Blogger Template Responsive Wordpress Theme Review and Rating Stars run android apps on pc SEO Shop Sketch App Files Social Media Icons Software Templates Text Effects Textures ThemeForest Themes Timeline Remove Tips Tools & Utilities Top Download Trial Buy Buttons Tricks UI & Mobile Apps UI Element UI Elements UI Kits Uncategorized vector ribbons vectors Web Buttons Website Layouts Website Traffic Websites Windows Wordpress Plugins Wordpress Themes

Sunday 15 April 2012

Custom 404 Error Page For Blogger

404 Error

"The 404 or Not Found error message is a HTTP standard response code indicating that the client was able to communicate with the server, but the server could not find what was requested." In simple words the page that will be displayed when the actual page is not found is called a 404 Error Page. Till now Blogger’s error page was a plain old design with more of orange in it and was not customizable. Now Blogger Error pages use the same template . This would help template designers in making up custom 404 Pages.This tutorial will help you in setting up a Custom 404 page for your Blog.

By Default, your Blogger Error page will display this error message.Default

You can Change this message to something else from the Blogger Settings.
The option is there at Settings > Search preferences > Custom Page not Found
Search

If you want more than just a message, then we will have to fill up this text area with some HTML Code. 
It's Look Like That Click Here :-

Instructions:
  • Login to your Blogger Account and go to the Template page and proceed to Edit HTML
  • Click on the Expand Widget Templates Check box so that your entire template comes up
  • Now Find for </head> and immediately before that paste this snippet

<b:if cond='data:blog.pageType == "error_page"'>
<style type="text/css">
.status-msg-wrap {
font-size: 100%;
margin: none;
position: static;
width: 100%;
}
.status-msg-border {
display:none
}
.status-msg-body {
padding: none;
position: static;
text-align: inherit;
width: 100%;
z-index: auto;
}
.status-msg-wrap a {
padding: none;
text-decoration: inherit;
}
</style>
</b:if>

This code snippet will reset the default styling given to the Blogger Message Wrapper.
  • Save the template and go to a page on your blog which doesn’t exist.
  • You should be able to see the change now. The grey background and the border around the 404 status message would no longer be there.
  • Now Let’s see how we can improve the look and feel of our 404 page. I would suggest you to use inline CSS styles to improve the look and Feel of your 404 message. Here is a sample HTML template which you can paste into the text box at Search Preferences > Custom Page Not Found.
<h3>Your requested page was not found</h3>
<p>Sorry, we cannot find the page that you are looking for. It might have been removed, had its name changed, or is temporarily unavailable.<br/>
Please check that the Web site address is spelled correctly.</p>
<b>Other things to try:</b><br/>
<ul>
<li>Go to our <a href="/">home page</a>, and use the menus or links to navigate to a specific post.</li>
<li>
<form method="get" action="/search">
<table width="100%">
<tr>
<td><input type="text" style="width:95%;padding:2px;" value="Search this blog.." onfocus="if (this.value == &quot;Search this blog..&quot;) {this.value = &quot;&quot;}" onblur="if (this.value == &quot;&quot;) {this.value = &quot;Search this blog...&quot;;}" name="q"></td>
<td><input type="button" Value="Search"></td>
</tr>
</table>
</form>
</li>
</ul>
  • It will give you something similar to my 404 page.
  • If you are creative, you can add more stuff to the 404 pages. You can find a list of really creative 404 pages on HongKiat for inspiration.
Detecting an Error Page :-
Blogger has introduced a new page type called "error_page" and you can detect it using b:if conditional tags.
The following condition checks if a page is an error page or not.
<b:if cond='data:blog.pageType == "error_page"'>
This is an Error Page
</b:if>
Changing the Error Page Title :-
By default the title of the Blogger Error Page is your Blog Title. If you want to change it to something else, you can Edit your template and change.
<title><data:blog.pageTitle/></title>
To
<b:if cond='data:blog.pageType == "error_page"'>
<title>Page Not Found</title>
<b:else/>
<title><data:blog.pageTitle/></title>
</b:if>

And if you are using my Title Tag Hack or derivatives of that available on the internet, then you will have to change.
<!-- Start www.softarea.in - Changing the Blogger Title Tag -->
<b:if cond='data:blog.url == data:blog.homepageUrl'>
<title><data:blog.pageTitle/></title>
<b:else/>
<title><data:blog.pageName/><b:if cond='data:blog.pageName'> - </b:if><data:blog.title/></title>
</b:if>
<!-- End www.softarea.in - Changing the Blogger Title Tag –>
To
<!-- Start www.softarea.in - Changing the Blogger Title Tag -->
<b:if cond='data:blog.url == data:blog.homepageUrl'>
<title><data:blog.pageTitle/></title>
<b:else/>
<b:if cond='data:blog.pageType == "error_page"'>
<title>Page Not Found</title>
<b:else/>
<title><data:blog.pageName/><b:if cond='data:blog.pageName'> - </b:if><data:blog.title/></title>
</b:if>
</b:if>
<!-- End www.softarea.in - Changing the Blogger Title Tag –>
As I always here, if you get into troubles, you can use the comment form or Our Facebook Page !

0 comments

Post a Comment

Thanks For Visit :)

Note: only a member of this blog may post a comment.