2009/02/24

Creat auto "Read More" ( New version-Support thumbnail)


If you want to use "Read more" that you don't have to add <span class="fullpost">.You will be in difficult with fixing your entries, it can be crashed because of "Read more".

So now I will lead you how to create auto "read more" supports thumbnail.
With this version ( I will lead you to create auto "read more" with no thumbnail in another post), it will take the 1st picture in your post to appear in homepage.This is from vietwebguide.com,that place you can view the full source but I hope you understand VietNamese.


Go to Layout--->Edit HTML----> Expand widget templates, find this code <data:post.body> and change it by this code instead:

<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'>--&gt;Read more...</a></span>
</b:if>
<b:if cond='data:blog.pageType == &quot;item&quot;'><data:post.body/></b:if>



Then you have to add this code before tag </head> :
<script type='text/javascript'>
summary_noimg = 430;
summary_img = 340;
img_thumb_height = 100;
img_thumb_width = 120;
</script>
<script src='http://www.hotlinkfiles.com/files/2577506_b4sab/read-more_auto.js' type='text/javascript'/>


Notice the red code:

summary_noimg :the characters summary describe your entries that dont have image.summary_img :the characters summary describe your entries that have image
img_thumb_height : image height (pixel)
img_thumb_width :image width(pixel)

When done , your entries will look like this:


Or you can view another simple "Read more" form, click here for instructions.

Well if you have any problem, please contact me.
thank you and good luck


10 comments:

Smsrush said...

Very interesting tricks but I'm confused that how can I change the read more icon. Plz help. mail me on http://www.emailmeform.com/fid.php?formid=302721

[relaxation music blog] said...

No Work

vuluganck said...

Let me check it, the websamba.com has been shut down 2 days ago.I will upload the file to another service.Please come back in 1 hours

vuluganck said...

I have fixed, please try again.Thanks much

Emtoi’s Blog said...

My site don't Creat auto "Read More" ( New version-Support thumbnail) :((

Demo: http://webparkgirls.blogspot.com/

vuluganck said...

@Emtoi
Probably you have hacked your template many times.So please click on "Revert template to default" and do it again.The code is not wrong.
Good lucj

Desh said...

Hello!

Can you please send me the java script file of http://www33.websamba.com/anhvosite/blogger/js/summary-post-v20-test.js

It doesn't seem to work.

Thanks a lot and all the best!
Cheers!

vuluganck said...

Ok its here, you can go through this link and download it then upload it to your favorite host, don't use it directly because I use limited host.

http://zendersto.110mb.com/summary-post-v20-test.js

ipsj said...

i want to show the original size of thumbnail like your blog.but the pixel setting destroy the picture in read more looks.
plz help

Bd said...

Its not working again.... Plz give the link of summary-post-v20-test.js because its not working on 110mb.com ! Thanks !

Post a Comment

Thanks for reading , if you have any problem please leave me a comment here I will help you by my best.Please note that you put the friendly words tohelp each other to improving and developing these tips to be better,or the best way for you to track my blog is subscribing my Feed.You are always welcome on Zenplate.
Best regard
Zen

 
.