How to create static pages on blogger

In this simple tutorial i will show you how to create static pages within your blog on blogger so you can easy link to them from navigation links within your blog these could be any page you like such as "about me" and "contact me" pages.

so the first thing would be to either use a test blog or download a backup copy of your template before doing this to your blog as i cannot be held responsible if you mess up your blog.

Once you are ready go to your blog and create a new post using whatever title you want for this tutorial i gave mine the title of "About" now add your post content when you have finished click the "Post Options" link found at the bottom of the post editor see screenshot below




now we need to change the date of the post to something older than your first blog post that way it will be hidden in the archives next under "Reader Comments" click the last radio button to disable comments since we don't want people commenting on these static pages do the same for the Backlinks next publish your post and visit it note how the date, time, email post icon and posted by are all showing up and whatever else you have installed below the post footer such as social bookmarks.

Well here's how we can get rid of them on the static pages which we don't allow reader comments go to layout > edit HTML expand the widget templates and find the following code

<span class='post-comment-link'>
<b:if cond='data:blog.pageType != "item"'>
<b:if cond='data:post.allowComments'>
<a class='comment-link' expr:href='data:post.addCommentUrl' expr:onclick='data:post.addCommentOnclick'><b:if cond='data:post.numComments == 1'>1 <data:top.commentLabel/><b:else/><data:post.numComments/> <data:top.commentLabelPlural/></b:if></a>
</b:if>
</b:if>
</span>


now the code highlighted in red basically checks to see if we allow comments on the post if it does then the code within the tags will be shown otherwise nothing will be shown

so we need to wrap the post date, time, posted by and whatever else you don't want showing within the tags so they are not shown on our pages which do not allow comments

here's an example of the timestamp, posted by, and email icon wrapped within the tags as described above

<b:includable id='post' var='post'>
<!-- Code removed for simplicity -->
<div class='post-header-line-1'/>
<div class='post-body entry-content'>
<data:post.body/>
<div style='clear: both;'/> <!-- clear for photos floats -->
</div>
<div class='post-footer'>
<div class='post-footer-line post-footer-line-1'>
<b:if cond='data:post.allowComments'>
<span class='post-author vcard'>
<b:if cond='data:top.showAuthor'>
<data:top.authorLabel/>
<span class='fn'><data:post.author/></span>
</b:if>
</span> <span class='post-timestamp'>
<b:if cond='data:top.showTimestamp'>
<data:top.timestampLabel/>
<b:if cond='data:post.url'>
<a class='timestamp-link' expr:href='data:post.url' rel='bookmark' title='permanent link'><abbr class='published' expr:title='data:post.timestampISO8601'><data:post.timestamp/></abbr></a>
</b:if>
</b:if>
</span> <span class='post-comment-link'>
<b:if cond='data:blog.pageType != "item"'>
<a class='comment-link' expr:href='data:post.addCommentUrl' expr:onclick='data:post.addCommentOnclick'><b:if cond='data:post.numComments == 1'>1 <data:top.commentLabel/><b:else/><data:post.numComments/> <data:top.commentLabelPlural/></b:if></a>
</b:if>
</span> <span class='post-icons'>
<!-- email post links -->
<b:if cond='data:post.emailPostUrl'>
<span class='item-action'>
<a expr:href='data:post.emailPostUrl' expr:title='data:top.emailPostMsg'>
<img alt='' class='icon-action' height='13' src='http://www.blogger.com/img/icon18_email.gif' width='18'/>
</a>
</span>
</b:if>

<!-- quickedit pencil -->
<b:include data='post' name='postQuickEdit'/>
</span>
</b:if>
<!-- Code removed for simplicity -->
</b:includable>


and the post date


<b:includable id='main' var='top'>
<!-- posts -->
<div class='blog-posts hfeed'>
<b:include data='top' name='status-message'/>
<data:adStart/>
<b:loop values='data:posts' var='post'>
<b:if cond='data:post.allowComments'>
<b:if cond='data:post.dateHeader'>
<h2 class='date-header'><data:post.dateHeader/></h2>
</b:if>
</b:if>
<b:include data='post' name='post'/>
<b:if cond='data:blog.pageType == "item"'>
<b:include data='post' name='comments'/>
</b:if>
<!-- code removed for simplicity -->
</b:includable>


you can use those tags as many times as you like through your template and put anything within those tags that you don't want showing up on your static pages so basically we need to use these tags within the post loop

<b:if cond='data:post.allowComments'>
(normal pages this post allows comments)
comment link, email post etc .. go here
<b:else/>
(static pages post's that do not allow comments)
anything you want to show on static pages goes here
</b:if>


so now you should know how to create static pages within your blogger blog take a look at my privacy policy created using the steps described above

i hope you enjoyed reading this tutorial if you are having any problems leave your comment and let me know i will get back to you as soon as i can

28 Responses to “How to create static pages on blogger”

I've been wanting to do this...yet I can't seem to understand the codes here yet...LOL Let me read and re-read this one.

Thanks!

Anonymous

May 26, 2009

you can not be a teacher! :D lol its a little confusing!

@Anonymous
whats confusing ?

Did not got it.
www.techieway.blogspot.com

@Sandeep
did not got what ? if you disable comments on a post and wrap the following code

<b:if cond='data:post.allowComments'>
content here will not be visible if the post doesn't allow comments
</b:if>

around things you don't want to show within that post they are not shown

thanks heaps for the tut..i've been looking for this for ages..can't wait to give it a go..

What do you mean by "wrap the post date?" What does wrap mean?

@Jeff Branch
if you nest or wrap those tags around the post date then create a post and disable comments for that post the date will not be shown when you visit that post for example

<b:if cond='data:post.allowComments'>
<!-- only show the date if the post allows comments -->
<data:post.dateHeader/>
</b:if>

I did it...and I did it successfully at first try and in my other sites as well!

Now...it's not really confusing as it seems at first look.

The first codes were just shown to us to understand how it works...then the in the following codes, the ones in red were the one we need to add to our code. The conditions there (codes in red) will function everytime we make a post and disable funtions in the foot of our post like author, tags, date, etc.

Thanks so much!!!

@Mariposa
yes thats right I'm glad you was able to follow my tutorial

Hi Lawny,

Could you please show me how to make the author name,date & time post go next after the post title?

Example:

"How to create static pages on blogger" by Lawny on 23 June 2009 02:22am.

please help!

@Ezri
i might write a post showing how you can customise the post template when i get time however i cant promise you

Impressive! You're rocks! It helps me to make my blogspot blog look more pro. Thanks for this.

I dont get it i cant find some of the codes you said there would be therefore i am mortally CONFUSED. i just dont understand!

Reanna4eva.

@Reanna4eva
make sure you have expanded the widget templates otherwise you will not see the codes such as <data:post.dateHeader/>

Oh wow! Thank you force this tutorial. I'm really looking to renovate my blogs and make them more functional.

Thanks again.

great blog .. i'll try it now ,it looks very nice ...thanx

This is the best static page article, the others on the internet didnt explain how to remove author.

I have a different template that doesn't use the data:post.dateHeader/ tag. I've tried wrapping around any tags that look similar (i.s., have "date" in them), but nothing seems to get rid of the date. I have everything else worked out.
Any advice?

@Evangeline
where did you download the template from ? the designer may of removed the code

Figured it out! My code used timestamp instead of dateHeader, since the date is on every post. Thanks for a great trick!

@Evangeline
I'm glad you was able to figure it out

Hi. I found this tutorial a little tricky to follow, as I was just guessing which bits of code I had to wrap, but I did manage to set up the page and delete most of the stuff I didn't want. I am still left with this stuff though, and I don't know how to get rid of it:

0 Response to "Email our teacher"
Newer Post Home
These bottom two are links. There wasn't a place in my Post Options to allow or not allow backlinks.

I am using a converted Wordpress template.

Hope you can help.

@Catherine
the template you are using will of been customised so you may need to search for the codes they will be in a different place

Lawny: Help, help, help .....please!!

My blog has a main page where only the welcome message is displayed. I have created tabs for "static pages" (Memories, Recipes, Photos, Tips, etc.) on the menu bar, but am unable to post to those pages. If you click on one of the tabs, the correct page is accessed but when I create a New Post - it goes to "cyber space". I can go to Edit Post and click view and see the post, but am unable to get it to the correct page.

My blog is msporch.blogspot.com. I would appreciate any advice that you have time to share.

Thanks much,
Sarah

@Sarah
it sounds like you have either put the tags in the wrong place or deleted them

I attached the tags, using HTML, as a gadget on the layout. They haven't been deleted - as stated earlier, I can access the page but am unable to get the post attached to the page.

Should the tags be elsewhere?

Sarah

@Sarah
I know the navigation links haven't been deleted when you click the navigation links on your blog only the post title is displayed on the page because you have either deleted the <data:post.body/> tag or put it in the wrong place so i recommend you read the tutorial more carefully also i can't really help you as i'm too busy working on other sites unless you want to hire me

Leave a Reply

Feel free to leave your comment however comments are moderated before appearing on site

Copyright © 2009 All Rights Reserved | Privacy Policy | Disclaimer Design by LawnyDesigns | Powered by Blogger