Friday, December 2, 2011

Shorten your Blog Posts by adding "Read More" Link

Quick loading time for your website is crucial in retaining visitors. Almost 75% of Internet users do not return to sites that take longer than four seconds to load. So adding the read more link to the posts on your homepage can help save time, by minimizing the length of your blog posts and not loading all images. (Skip to the bottom to see a preview)


>This method will apply automatically to ALL of your blog posts on the homepage. If you want to be in control of where & when you want to add the Read More function, click here.



1. In your blog options, click Template on the left side of your screen.



2. Cick on Edit HTML

3. Check the box next to Expand Widget Templates


4. Now find, <data:post.body/>. ( You can find that by pressing Ctrl +F and pasting in this code into the find box.)

5. Replace it, with:
<script type='text/javascript'>
summary_noimg = 430;
summary_img = 340;
img_thumb_height = 100;
img_thumb_width = 120;
</script>
<script src='http://blogergadgets.googlecode.com/files/excerpt.js' type='text/javascript'/>
<b:if cond='data:blog.pageType != &quot;item&quot;'>
<div expr:id='&quot;summary&quot; + data:post.id'><data:post.body/></div>
<script type='text/javascript'>createSummaryAndThumb(&quot;summary<data:post.id/>&quot;);</script>
<span class='rmlink' style='float:right'><a expr:href='data:post.url'>Read more</a></span>
</b:if>
<b:if cond='data:blog.pageType == &quot;item&quot;'><data:post.body/></b:if>



6. Click on Save Template. And you're Done!

Preview:

I initially really liked this layout, but when this applied to my gallery and contact pages, I had to remove it because by shortening those pages, the full post simply wouldn't open up after clicking the "read more" link. So I'm back to manual Jump breaks.
You can always change back by reversing this method.

This article is copyrighted and owned by http://greenfridge.blogspot.com

3 comments:

Javed said...

Pak job Ads and advertisements for Karachi,Lahore,Quetta,Peshawar,Multan,Hyderabad,Rawalpindi,Islamabad andhttp://allpkjobz.blogspot.com all cities of Pakistan.

arun said...

Great this is absolutely easy to do!!! thanks a lot!

Anonymous said...

I lіke the helpful infοrmation you provide
in youг artіcleѕ. I will bookmаrk your weblog and check again heгe regularly.
Ι'm quite certain I'll leаrn lots of nеw stuff right here!
Best of luck for the next!
Also see my site: tiny url