Thursday, July 15, 2010

cara buat readmore

Posted by Cikgu Ma at 1:34 AM
cara buat readmore

logger Help - Add Read More link to your posts

Although this tutorial is the easiest way to truncate posts on Blogger blog, but being a javascript based hack, this method is not SEO friendly. If you want to use a SEO friendly post-truncating method on your blog, then kindly read this post.
Most of the bloggers, want to show more than one post in their blog's home page, but displaying all the content on the home page of each and every post makes the home page very lengthy, and visitors may miss out any article while scrolling down the entire length of the page.
So here's a method for bloggers to display only a part of the posts, and not the entire posts. If a visitor wants to read the complete article then he/she will click on the "Read More" link at the bottom of the post, which will be redirected to the particular post.

Steps to follow:
1. Log into the Blogger.com account
2. Go to "Layout" section
3. Back up your current template, by downloading it.
4. Now click on "Expand Widget Templates"
5. Now find this code - ]]>
6. Just AFTER that code add these lines



7. Now again find this code :
8. And just after this, add these code lines:


Read More!



If you want to shift the "Read More!" text to the extreme-right side, use this code:


Read More !



9. Now save the template.

IMPORTANT :Now these adjustments will NOT show your previous posts with "Read More" tag, but you can display them with Read More tags, by editing them with instructions as below:
From now on, whenever making a new post, the part of the post you want to HIDE on your main homepage, write those lines in between these code lines:

WRITE THE PART OF THE POST YOU WANT TO HIDE HERE


See the screen shot below for details:


NOTE 1: After writing new posts, always proof-read your edit HTML section, to avoid mistakes, one such mistake is discussed below:

Make sure, that "Edit HTML", while writing posts looks exactly like this:

Post in brief, may include pictures too
Hidden part

In the above example notice that I have closed span, before div, that placement is very necessary, if you put like this
, i.e. closing div first and span later this will NOT work, because span has been started inside div, so it must be closed within div tag.

In case you have multiple paragraphs, while posting a post, and you are giving same text alignment to all the paras, then by default, after every para, the div element will be closed, and again it will start for the next para, so THIS SHOULD NOT be like this, you have to start
in the beginning of the post, end it at the last, and make sure Hidden part, is between your div tags.
If you want your previous posts also to hide part of their text, then you must edit them and add span tags to them.


*UPDATE: Now there's a new hack to make all this process automatic: READ HERE about AUTOMATIC READ MORE trick for Blogger.

NOTE 2: If the above method does not work in your blog, here try this second method:
eBlogTemplates

0 comments:

Post a Comment

 

...tutorial blog koi... Copyright © 2011 Designed by Ipietoon Blogger Template Sponsored by New Baby Shop