As you can see in this post, it starts with only the summary, followed by the 'Read more...' link. Clicking the link expands to the full post. Now at the bottom you will find a 'Summary only...' link, that collapses the post back to its summary.
This hack was first implemented by Ramani at Hackosphere. I expanded on it to make it collapsable. Together we developed the finishing touch of hiding the expand/collapse link when there is no need for them.
This is how to implement it.
Step 0:
Back-up your template before modifying it.
Step 1:
Add the following javascript code to the head of your template. You can place it just above the </head>-tag.
<script type='text/javascript' src='http://www.anniyalogam.com/widgets/hackosphere.js' />
Step 2:
Find the includable named 'post' in your template, and change it so that it is exactly as shown below (the code in red has to be added):
<b:includable id='post' var='post'>
<div class='post'>
<a expr:name='data:post.id'/>
<b:if cond='data:post.title'>
<h3 class='post-title'>
<b:if cond='data:post.url'>
<a expr:href='data:post.url'><data:post.title/></a>
<b:else/>
<data:post.title/>
</b:if>
</h3>
</b:if>
<div class='post-header-line-1'/>
<div class='post-body' expr:id='"post-" + data:post.id'>
<b:if cond='data:blog.pageType == "item"'>
<p><data:post.body/></p>
<b:else/>
<style>#fullpost {display:none;}</style>
<p><data:post.body/></p>
<span id='showlink'>
<p><a expr:onclick='"javascript:showFull(\"post-" + data:post.id + "\");"' href='javascript:void(0);'>Read More...</a></p>
</span>
<span id='hidelink' style='display:none'>
<p><a expr:onclick='"javascript:hideFull(\"post-" + data:post.id + "\");"' href='javascript:void(0);'>Summary only...</a></p>
</span>
<script type='text/javascript'>checkFull("post-" + "<data:post.id/>")</script>
</b:if>
<div style='clear: both;'/> <!-- clear for photos floats -->
</div>
</div>
.... rest of template code ....
Save your template.
Step 3:
In the Settings - Formatting tab go to the bottom and enter the following post-template:
Type your summary here.
<span id="fullpost">
Type the rest of your post here.
</span>
Now every new post you start will have a fullpost-span by default. If your post is short, you can delete the <span>-tags from the post. The post will be displayed in full, and no links with "Read more..." or "Summary only" will be displayed for that post.
How it works (skip this if you don't like tech stuff).
The changes you made to the code make that every post-body consists of at least 3 span's: the fullpost-span that you entered in the post-template, a span for the 'Read more'-link, and a span for the 'Summary only'-link. Because there might be other spans in your post, each of these 3 spans have a unique id ('fullpost', 'showlink' and 'hidelink' respectively).
When you open your blog on the main page, the post is displayed as follows:
- Summary is displayed (always)
- Full text is hidden (first div, set to display:none)
- Read more is shown (second div)
- Summary only is hidden (third div, set to display:none)
The post is given a unique id, and this id is passed to the javascript-functions showFull and hideFull respectively. These functions use the getElementsByTagName-methods to obtain handles to the spans, and then toggle the way they are displayed.
A third function, checkFull, checks if the Fullpost-span exists. If not, both links are hidden.

This is what people say:
Thanks Hans, this is really great. Got your link from Ramani. All of you are my angels.
Hans, are you still interested in making hacks for non-beta templates?
I found these two links Link 1
Link 2 in blogger help maybe you can improve this to make a super peekaboo post too.
I am just desperate since I can't move to beta and I wanted this hacks so bad. I wish you can help me.
Raquel
hi, nice work.
will this work in non-beta blogger?unfortunately,blogger has not yet updated my blog.thanks
Hey,
I would be very interested in usign this hack, but I cannot find the 'includable' line of code in my template (Minima), not any other lines after it. I'm very new to blogging and I'm on beta.
Hope this makes sense,
Best,
irishelectionstudy
works like charm! thanks for the update.
@all: thanks for the compliments, and please use the hack and spread the word!
@raquel: I will look into the possibility of a non-beta version of this hack (but isn't one already out there somewhere?). Be back with you soon.
@chllout_lev: no, this hack is beta-only, but the principle will be the same for non-beta. Non-beta uses template tags, while beta uses widgets. Check back later.
@zbyszek: did you check the "Expand Widget Templates" box? You will need to do this to show all the widgets.
Well guys & galls, Super Peek-A-Boo Posts are now available to Non-Beta Bloggers as well.
Check this out.
It works brilliantly! I am very new, so I had a few goes at it before I got it working, but it works a treat and I am so happy.
Thank you so much - I will sleep well tonight.
It worked fantastically on a new test blog!
But if I want it on my real blog I would have to modify all the old posts individually to the new post template right?
If so I'll have to save that job for a long weekend.
Thanks Hans, but it seems I have a little problem after the hacking done....there is text like this
expr:id='"post-" + data:post.id'>
after every post title and I think it's not going well..no summarize etc.
I've done with test post...
please check here http://luqluqq.blogspot.com
@zbyszek: thanks! and sleep well...
@ben: all your old posts will stay exactly as they were: non-collapsable, and without Read More-link. If you want to make them peek-a-boo-style, you have to edit them and add the <span id="fullpost"> and </span> tags around the bodies.
@luqluq: The most failsafe way is to copy-paste evrything into your template, just to avoid typo's.
I can't see any problems at your blog, besides that there are no read-more-links. If you like I could look into your template of you send me a the xml-file.
It works briliantly! Thank you Hans.
This is first on my list for when I get back from vacation! We leave in the morning for one glorious week in sunny Mexico!!!!
You have been busy, and I've been slacking. But, I've been extremely busy this last week. (Excuses, excuses....but really. Planning a vacation is exhausting.)
Keep up the good work.
Hans,it's wonderful!
But there is a problem for me.
i am a Chinese blogger,and i find i can't connect to the file at this address:
http://www.anniyalogam.com/widgets/hackosphere.js.
so,i can't use the latest version of this "Peek-a-boo posts" hack,and i have to use your earlier version,but it's not perfect.
maybe u could help me deal with it.
thanks a lot.
here is my blogspot:
http://oyee.blogspot.com
and my email:icomesee#gmai.com
@alex: I have no clue why you can't connect. Might it have anything to do with charactersets or so? Maybe you can contact Ramani about the sources.
Can you download the .js file by entering its path and name in your browser adress-bar? See if you can connect that way.
Found this sit through Ramani's. Thanks for this great hack, it's a great improvement over the previous version.
@jason: you are welcome!
Annie:
Mexico uh?, great, let me know what part of my country you were.. :P
and happy vacations.
Hans,now i know why i can't download the .js files used in this Super Peek-A-Boo Posts Hack.
the site" http://www.anniyalogam.com/" has been blocked in China.so i have to download the file through web proxy.
i believe that's why your websites (and Ramani's) been loaded very slowly.actually,i can't see this hack'seffect in your sites and Ramani's all the time.
maybe u could put the .js files to another site,so our Chinese blogger can use this hack easily.
@Alex: I think that would be hard to do, as all users of our hacks now link to Ramani's site for the js-file. We try to keep one source for the code. I suggest that you download the js-file via proxy, and add the javascript-functions to your blog, or host them from a site that is not blocked in China.
Good luck!
hi,i want to know how to display the code in the post,but the code wouldn't carry out ?
just as your code in the post!
can you email me ?
coloor@gmail.com
@咖啡鱼: You have to replace each <-character with 4 characters: < and each >-character with >.
lt stands for "less than" and gt stands for "greater than". This is a general way to display special characters. Quotes are done with " ("). The copyright symbol is done with © (©)
You can find these codes on internet in any html-manual.
Hans,
can you check this comment in my blog and see if you are interested in working on it. I got no time right now :(
http://hackosphere.blogspot.com/2006/09/peekaboo-posts-improved-again.html#comment-4955997123792669283
Ramani, I'll check it out, but me too has much work to do the upcoming week or two.
Know what: we'll set up a wish-list. Okay? And inform our audience on progress.
Hi..
I badly want to have expandable summaries in my blog
I am on beta
when i try to locate -b:includable tag.. i am not able to locate it in my template .
( i am using waves template from http://www.pannasmontata-templates.net/.. with few modification..
viz.. BG clor -border clor- font style..))
also i donot see "expand widget" chek box.
I was uing blogger classic..
got myself upgragraged to beta
So can you please help me in implimenting expandable summaries
Thank you
Deepa
@Deepa: If you have converted your Blog to Beta, the next thing you have to do is change your classic template to a new Beta Layout.
Take a look at the dashboard. I think that you have options "Posts", "Settings" and "Template". You have to upgrade your template to a Beta Layout if you want full Beta functionality (such as labels). If you have upgraded, the "template" option in the dashboard will change to "Layout".
Be assured: if you upgrade to a layout, you can switch back to your classic template if you have second thoughts.
Upgrading to a Layout means that you lose the Pannasmontata waves-template. (You could however adapt the Waves template to match with the id's and classes that Beta uses).
So you have to upgrade to Layout first before the Peek-A-Boo hack works.
Or, if you don't like to upgrade yet, you could implement the Peek-A-Boo for non-Beta, that will work with the classic template.
Hi Hans,
Back to trouble you again. I tried this on my Beta blog but when trying to save the template after inserting your code, I keep getting the following error message :
Your template could not be parsed as it is not well-formed. Please make sure all XML elements are closed properly.
XML error message: Element type "div" must be followed by either attribute specifications, ">" or "/>".
My blog is http://milindsmusings.blogspot.com/
Regards,
Milind
Hi Milind, the code that is given in this post will work fine with your blog, as it is working for others as well. So let's set out a strategy for you to get this up and running.
First of all, the error message that you posted suggests that you make a mistake when you are editing the <div class="post-body">. If you add the expr:id='"post-"+data:post.id' to this div, be sure that you have all the quotes, colons, spaces as they should be, and that there is a closing >.
In general, it is better to copy-paste the code than typing it in, just to avoid typing-errors.
So I suggest you backup your current template by downloading it from the html-edit-page. Then insert the expr:-code into the div, and try to save your template.
This way, you could copy line by line if you encounter problems, and so pin-point the place where things turn sour.
Don't forget to add the hackosphere javascript to your template's head. And also add a <span id="fullpost"> to your post template.
Thanks for the help, Hans. Yes, there were some typos causing the problem.Got it working now. :)
Your blog is simply wonderful. I seem to be spending all my on-line time tweaking my blogs nowadays!
thx guys.... this will probably help my readers to NOT snooze on their keyboards, as my posts tend to be rather long!!!!
@milind: glad to have been of help!
@lux: hope to see you more often here.
hey Hans Ive done exaclty what you've specified but I cant save the template. I'm getting this message.
"Your template could not be parsed as it is not well-formed. Please make sure all XML elements are closed properly.
XML error message: Element type "div" must be followed by either attribute specifications, ">" or "/>"."
What must I do??!
@Don Yuan: fellow blogger Milind had the same problem. Check out her comment and my reply to it.
Ive tried a fifth time. Now I'm getting this!
Your template could not be parsed as it is not well-formed. Please make sure all XML elements are closed properly.
XML error message: The element type "b:includable" must be terminated by the matching end-tag "".
Man this is discouraging!!! :(
Hi Don, I know the feeling, it happens to me all the time as well.
In most cases, it is caused by typing errors. If you miss one quote, colon or bracket the thing just refuses to save.
It is best not to type the code, but to copy-paste it. And do it line-by-line, saving after every line. Then you can pin down the mistake to one line, and easily remove the mistake.
You will succeed!
IVE DONE IT!!!! :)
The last line of your code "/div" was interfering with one piece of code I already inserted in my template. This technique of Line by Line & copy-paste really work! I recommend to anybody who's getting problem!
N yeah HANS thnx a lot to you! Your blog is definitely worth the visit! I've linked up to you!
Anyway keep up with the good work and you will sure continue to have faithful visitors like me!
Regards,
Don
It does work indeed! I had been looking for a code like this for a few days. Thanks a lot, it worked great on our blog. My girlfriend will be very surprised
Jonzie, congratulations!
Hans, you rock. I am having a problem removing the "read more" link from every post kevwrex.blogspot.com. I was trying to implement peek a boo and changed my mind. I don't know what I should remove from the template to get rid of this dead link. Suggetions?
Hi Hans!
Ive tried your "read more" hack but for some reason when viewing my blog with IE 6 or 7 only the first article appears, on FF and Opera everything works fine.
Can anyone tellme how i can get a clean template? i reversed my template to oldest backup i have and still when i implement the hack the problem arises again
I checked all the steps and code.´
Thanks
Is this code free? I have put it on my blog. If that is a problem I can remove it.
It is a great code...
Hans, awesome hack. I've insluded it in my other blog. I'll keep my tabs on your blog.
Thank you.
Thanks a lot, Hans. I have it working now on my site as well as the three column format.
For some reason youtube clips screw up the three column set up... any ideas why? I wonder if I need to re-submit my blog to youtube.
dude hit me back if u interested in swapping blog links
Thanks - jeff
http://www.netskool.blogpsot.com
Thnx for this hack hans. Ive already implemented the hack successfully and given you credits here.
http://howtoin7seconds.blogspot.com/2006/11/how-to-hack-your-beta-template-in-7.html
I just want to change it a bit. I display only 3 posts on the main page of my blog. If the user click on the Read More of a post, I want it to display in the post's own page. (That is only this post gets displayed on a single page of my blog)
Can you tell me how to do this?
Thnx...
@kevwrex and ricardo: I checked your Blogs and it seems to be okay now.
@theologian: its free like the sun!
@henry: thanks!
@ohdave: as far as I know adding a YouTube video to your blog means copying some html and pasting it into your post. I guess this html you paste into your post has a width-parameter set to a value that exceeds the width of your main-section of your template. The YouTube video makes your post wider than it should be, and the sidebars won't fit anymore and are dropped to the bottom of the page.
Solution: adjust the width of the YouTube html.
@jeff: thanks!
@yan sim: this will need an adaptation of the peek-a-boo hack. I will write a tutorial on it soon.
Finally got this to work after removing the second / div on step 2. excellent hack! Thanks!!
I'VE DONE! THANKS VERY SO MUCH! I've been searching this code...
Only one thing...It only works in the first page. When you push the link "Older post", and there one notice haven't summary, appears a "Read More" that if you push do nothing. Then appears a "Summary only...".
An example in your page: Move until "Tuesday, October 24, 2006" with "Older post" (only one click now). Look the post "Poll Closed", after "A simple Photo Album".
I hope I help in something. Bye!
@Googlemaniaco: yes, we've noticed this before. It seems that clicking the Older Posts link does not display a new page, but displays older posts on the same page. As a result, the javascript-function that checks for a fullpost-span (tech blabla) is not invoked, and the peek-a-boo thing will not work. We still have to figure out a work-around.
i've followed every steps that u mentioned and copy n' paste exactly wat u told in the post, but i couldn't save it, as the error said
"Your template could not be parsed as it is not well-formed. Please make sure all XML elements are closed properly.
XML error message: Element type "div" must be followed by either attribute specifications, ">" or "/>".
"
i really dunno wat went wrong >< please help
Hey there,
I got this to work on a test post, but then when I tried it on a much longer post, it didn't work the way I wanted it to. The "Read More" link just appeared at the bottom of the post, which isn't helpful.
http://thetoptens.blogspot.com/
Thanks for your help.
@neonplanet: you probably missed a closing-tag on a div. Check all the <div> tags to see if they are closed properly.
Hi Hans
I'm not able to apply your code into my template code. But I realy enjoy the look of it!! For instance: I have the "post" tag like ; div class="post", only!! I woud be happy to send it to you the full code!! It's not at all like the one in the sample you provided in the tutorial.
Thanks
Your explanations here are better than anywhere else. Thankyou.
@orumulu: the idea behind most tutorials is that you try to understand how stuff works by following the examples, and to be prepared that in your own templates things might be a little bit different. The idea of this hack is that your post gets a unique id. This id is needed so that the hack-software knows which post to expand. So look for the id that envelopes the entire post. That will be the one you need
I am also interested in the tutorial that you promised yan sim. Have you posted it yet?
@Theologian: take a look at Ramani's post for this trick.
Thanks
Hi Hans
I've tried out your non-beta hack and it just worked great! Thanks, nice work!!
Also I'd like to prevent copying of my images. How can I deactivate the
right-click/copy in my blog?
Thanks.
@oromulo: check out this script if you want to prevent visitors from downloading your images.
I would like the peek-a-boo post be the same as in classic blogger. I have so much trouble with posting, some time losing links and text, problems with pasting text, and fonts being consistent through the post; that I don't want to go back through my post and edit each one. It takes to long to make sure, I have not lost something.
THX.because of your help,my website is much better than before.
@hathor: you don't need to make all your old posts peek-a-boo. You can just leave them as they are, and use peek-a-boo for the new ones. If you set your postteamplate with the spans you need, there is little chance of anything going wrong.
@Coodar: you are welcome!
hi hans,
i'm not sure if anyone has this prob, but all the images that i place in between the /span tags appear in the "Summary" page. However, when i click on "Read more", the images fall back to the correct position (i.e. in the body of the post).
Is this a bug with images? PLs help! Tks loads!
Hi Hans .. first of all, let me say thanks for all the wonderful hacks you've come up with.. I've used several of them and they are absolutely divine.
Would like to ask if you could take a quick look at my website to see what's wrong with the peek-a-boo posts.. it's been working for almost a month and Ive only recently discovered that they were down. When I clicked on the 'read more' button .. the page is redirected to a 404 error page on Blogger.
Was this because of some changes made by blogger? or did I do something horribly wrong?
Please help .. thanks!
Hey Hans .. me again! I realized that I disabled Javascript on blogspot.com, hence the 404 error. So nothing's wrong after all :)
For all you guys out there, note that javascript needs to be enabled for this hack to work. Especially if you use the No Script extension for Firefox .. remember to set 'blogspot.com' as one of your allowed domains.
Happy holidays hans and everyone else!
@Lucy: I have images in my blog posts as well, inside the spans. They don't show up in the summary, only in the full post. So I guess you did something wrong with the spans.
First of all, have a prosperous and meaningful new year. I really liked this hack Hans. I right away implemented it, but the thing is, it works very well in Mozilla Firefox, but when I open my blog through IE, it does not work at all, it shows only the summary of first post and nothing else. I think I have missed something while editing the codes, can you please help me out.
I was very excited about this hack because I have some lengthy posts and wanted to be able to give readers the option to expand/collapse, but it just doesn't work. Even with the modification, it puts "read more" on every old post & the link leads nowhere. It is totally unacceptable.
Moreover, I couldn't figure out 1) where to put my text in my new posts or 2) how to manipulate the html on new posts. Unfortunately, by putting that code into the format setting page, it does not show up in the html of every new post.
Keep working on it, guys! I'm sure you can figure it out for Blogger, but you don't have it working just yet.
Hi Hans, I finally corrected the problem which I faced while viewing my blog through IE. I had wrongly entered the span codes. That prevented IE from displaying the blog prperly.
@Janie: the hack works fine if implemented correctly. As you can see on this blog and many others. So keep on trying, Janie!
@Seagull: good to see you succeeded!
does this work on new blogger as well , or just blogger beta?
i keep getting 404 error when i try to save template (even when i don't make any modifications to code- simply expanding widgets will do it.) what's wrong?
Hi Hans, pls help...can't seem to make the code work in my blog, http://jujucreations.blogspot.com and my post can't align properly after installing this code. Tks!
oops, there were errors in my span tags in my post. I got it fixed and all is working fine. Tks1
@ming: the 404-error means some server problem with Blogger, and has nothing to do with the hack.
@lmz: glad you solved it!
it works wonderfully!
just two questions-
1. is there a way to make the text of th e Read more/less link customizable to each post? instead of saying the same thing every time.
2. can the show hide feature be nested inside another?
ex. post summary > show more > show even more
thanks for your help!
Greate thanks to Hans! I'm bothered by the "read more" tag shown in all posts before I saw this article.
I just cannot get it to work.
Alltough i copy and paste line by line i always get stuck with the error:
"Ihre Vorlage konnte nicht analysiert werden, da sie nicht korrekt formatiert ist. Stellen Sie sicher, dass alle XML-Elemente ordnungsgemäß geschlossen sind.
XML-Fehlermeldung: The element type "b:if" must be terminated by the matching end-tag "". "
Please have a look at my source code!
http://wernerhabel.blogspot.com/
im getting this error:
Your template could not be parsed as it is not well-formed. Please make sure all XML elements are closed properly.
XML error message: The element type "b:includable" must be terminated by the matching end-tag "".
i was able to correct the error and it's working great now. THANK YOU!
I tried this from both Ramani's and your site. 1st could not save (not parsed) tried again, then could save.
Tried a post, but nothing just a blank page upon publishing. Going to the post, it displayed what I had written, but nothing else - no "read more" etc.
As my blog acts as website for my hashing group and needs to be on always, I had to remove the codes and so that previous posts are visible. Am using Minima template in new blogger.
What I noticed was this [script type='text/javascript' src='http://www.anniyalogam.com/widgets/hackosphere.js' ] was displayed upon saving as [script src='http://www.anniyalogam.com/widgets/hackosphere.js' type='text/javascript'], (using brackets here as HTML not accepted) could this be the problem?
wow gold
Tried once more and now it works just fine. Maybe it was my mood yesterday that prevented it from functioning. Many thanks to Hans and Ramani for this hack
Hans I am so depressed! I have been trying to do this for the whole weekend and feel sooo stupid. I recently switched to the new blogger and am trying to take over my style I used in the old Blogger by copying and pasting certain elements in the new Blogger layout. The template I was using is "Rounders 4" in the new Blogger layout. It says "Layout" and I have a the functions of the new Blogger.
However I cannot find the "b:includable id" anywhere on my template.
I am so new to all this and I really hope you can help me out! It took me ages to get the style I wanted on the old Blogger and I really like the ease the new blogger offers. But this is such a vital function for me and I do not want to miss out on it. Can you help me?
Meeta.. you should click on "expand widget template"...
Fantastic! It worked! Thank you arephyz's!
Hans, I also want to thank you for this. An amazing blog brilliant. Now to the next hack - another sidebar!!
Hi Hans,
Sorry to bother you again. I have been updating a few of my older posts and noticed that they all have the "Read More" even though I have not added id=fullpost to them. Short posts also have this. Is there a way have the "read more" bit only on those posts where you want them?
Hi, I love the Peekaboo hack. Unfortunately when I view it using IE 7 the right column of my template (Scribe) disappears and I can only read three posts. Everything works great on Firefox. So I had to remove the hack since the majority of the visitors to my blog still use IE. Any ideas as to how this can be fixed? My blog is http://xtraordinaryliving.blogspot.com/
Thanks
Rick
Hi Hans, I did exactly as you have written, step 0, 1 and 2 and when I save templatge, i keep getting this error message:
Your template could not be parsed as it is not well-formed. Please make sure all XML elements are closed properly.
XML error message: The element type "b:includable" must be terminated by the matching end-tag "".
Can u help please?
Hans - I have been using the Peekaboo posts for a few weeks and it is great. For some reason, the "Read More" shows up on all my entries even though I delete the span-tags. I read on your bug list that this is a common problem, but I didn't see if there is a solution.
Also, ever since I have been having the above problem, sometimes the peekaboo doesn't work for entries that I actually did use the peekaboo span-tags for. Suggestions?
hi, hans, this is a great hack and i appreciate it very much, it works great. but i've a little problem, as u can see from my blog (if u have that little time to take a look :p) the "show full entry" and "hide full entry" (actually it's a 'read more...' i just have the words changed) is at the right side of the passage, is there a way to move it to other position? thanks a lot :)
Hi Hans
I am experiencing the same (or a similar) problem as some others: your hack works fine on page 1 (adding 'Read More' only to the posts that have id=fullpost etc in them), but on subsequent pages (i.e. after clicking 'Older Posts') it adds 'Read More' to every single post.
See also:
Janie Hickok Siess' comment of 2 Jan 2007:
"it puts "read more" on every old post & the link leads nowhere"
Meeta's comment of 4 Feb 2007:
"I have been updating a few of my older posts and noticed that they all have the "Read More" even though I have not added id=fullpost to them. Short posts also have this. Is there a way have the "read more" bit only on those posts where you want them?".
craziasian's comment on 6 Feb 2007:
"For some reason, the "Read More" shows up on all my entries even though I delete the span-tags. I read on your bug list that this is a common problem, but I didn't see if there is a solution".
Are you working on this?
I am aware of your comments of 24 Nov 2006:
"Googlemaniaco: yes, we've noticed this before. It seems that clicking the Older Posts link does not display a new page, but displays older posts on the same page. As a result, the javascript-function that checks for a fullpost-span (tech blabla) is not invoked, and the peek-a-boo thing will not work. We still have to figure out a work-around".
Thnx for your good work!
hi hans
this is not working for my blogger beta ...i cudn't fig out what to change..cud u plz help me out..
my blog is www.techlivez.com
plz help me
error shown:
"The element type "b:includable" must be terminated by the matching end-tag "
and i mm doin exactly what is given in tutorial.
www.techlivez.com
hey i ve figured it out..
thanx man..
and sorry for posting 3 comments .
hey i ve figured it out..
thanx man..
and sorry for posting 3 comments .
I implemented it in www.delhievents.com & rechecked it few times in the past few weeks but it doesn't work even after ensuring that i did everything as suggested.
hi hans ,
i hv put all the codes as per u suggested ,i hv a problem
in each post i m getting
Type Your Summary Here.
Type Rest Of Post Here.
but now i dont know What to Write And where To Write To get That Peek a Boo Posts ,
plz help me out
Hiii,
I implemented this hack on (http://visitformoney.blogspot.com), but what i see is on my Older posts i can only see summary of Title not the posts. HOw do i make it work properly on my older posts also ?
Best Regards.
Eliena Andrews
http://visitformoney.blogspot.com
your codes is still error like as
Your template could not be parsed as it is not well-formed. Please make sure all XML elements are closed properly.
XML error message: The element type "b:includable" must be terminated by the matching end-tag "".
......pls check again your code...it is not working
mi ha mandato qui luigi (http://trovamiunnome.blogspot.com) e grazie alle tue indicazione ho migliorato il mio blog (http://ilmiodizionario.blogspot.com). grazie mille
Hans, I posted to Ramani's blog, but apparently he's on vacation.
I had your/his hack up on my site, and all was running fine until yesterday. All of a sudden no peek, no boo. The expand won't expand at all, and I never touched anything in the template.
Can you think of a reason why it should suddenly stop working? Is the .js file in the header corrupted or something?
Any advice is appreciated.
Dan
PS I really like the hack a lot, which is why I'm bummed that it's not working - thanks for making it!
Duh. Forgot to list the site. http://skinnydan.blogspot.com
Dan
@Dan: if I take a look at your blog, the links work well. The posts expand and collapse as they should. You might have had this bug on a page with older posts. The problem is, that clicking Older Posts does not refresh the entire page, it only refreshes posts. Therefore, the javascript is not called for the older posts, and you see links that should not be there, and links that don't work. Cant be solved.
Thank's, Hans
I've just copy-paste it in my blog with a little modification,
It work well so far.
Hi, Hans.
I put the hack in my blog and it works very well, but I have noticed some problems when using IE: posts expand and collapse as expected, but after the fist expansion the dinamic gifs of my page become static and the music stops.
In Firefox all goes perfect. Any idea? (apart of using FF that I can't assure for every people)
Hi Hans, according to IE7, there are some errors in the code of your page (see screenshot here). I have the same problem on my blog (screenshot here) on which I have installed your excellent Peek-a-Boo Posts widget. This widget is apparently where the error comes from (line number points to "Fullpost..."). The index.html of my blog doesn't load fully: IE7 stops reading the code when it arrives at the "Read more..." java link. That happens with IE7 only, not Firefox. A few weeks (or days?) ago, there was no problem with IE7 (which I rarely use). Could you solve that?
hey, ur psot really 100% works..
i love it..
Hi Hans, ever checked this very page with IE7? Cheers.
for some reason i dont have the post includable part. what can i do?
Hello All, I have an easy to implement hack on my blog...check it out...if you need a tutorial do lemme know...cheers,indy
Instead of changing all old posts,
could you please provide your hack with some modifications to display post with 255 chars.
vbbHi Hans,
thanks for your good hack..
Anyway.. I have a problem: only in the first page it works ok. In the older pages all posts have it at the bottom, also where it is useless (it appears just the "read more" text at the bottom of the post, obviously with no text to show by clicking on it..)
I saw that this is an old problem, but I didn't find any more recent solution.. Am I wrong? Did you solve it? I hope so...
Thank you,
Andrea
thanks sincerely for this hack, and all the work you offer. much appreciated! wondering if you could help with how you get the "(more)" peek-a-boo/expand thing you have in your sidebar? i searched but couldn't find a solution.
Between you and ramani, I can say that our site has benefited greatly from your contributions the community. Best of luck with future projects.
See it in action at:
http://commons.globalintegrity.org
Thank so much.
Hello Hans,
I've just installed a new template for my blog, the template is Andreas08. Before the new template I just used the snapshots template from blogger and the expandable peekaboo post works fine.
But now it won't work because one code is missing from the current layout.
After this code:
div class='post-header-line-1'/
there is no this code
div class='post-body'...
So I can't insert the required code as you instructed (to be this
div class='post-body' expr:id='"post-" + data:post.id')
Can you please suggest me what to do? Thanks alot!
@Finally Woken: the general idea of this hack is that we assign a unique number to the post, so that the javascript code can look for this unique number in order to identify which postbody should be expanded or collapsed.
Be sure to expand all template widgets in the template HTML-editor. Look for the post-includable (if you don't know what an includable is, read the Blogger template helpfiles). Inside the post includable you will surely find some kind of <div>-element, that contains the post body (you will also find some post header lines and post footer lines). Probably it has a different class-name, this might be the reason of not finding it). You need to insert the expression into this div-element.
Hello Hans.
I understand your point, and I have done this expandable peekaboo feature on my previous templates as well as my friend so I get the structure a bit.
But with Andreas08 template, I don't find the postbody code.
Correct me if I'm wrong, that I should look at this code:
b:includable id='post' var='post'
and the div class element should be right underneath, which I couldn't find (in Ramani it's called div class='post uncustomized-post-template', in snapshots template it's called div-class='post hentry', in your example it's simply called div-class='post', but all are under id='post', right?).
Also after this code
div class='post-header-line-1'/
there should be this code
div class='post-body'
which is missing too, so there are 2 lines missing.
so the complete code that I have right now is:
</b:includable>
<b:includable expr:id='"post-" + data:post.id' id='post' var='post'>
<a expr:name='data:post.id'/>
<b:if cond='data:post.title'>
<h2>
<b:if cond='data:post.link'>
<a expr:href='data:post.link'><data:post.title/></a>
<b:else/>
<b:if cond='data:post.url'>
<a expr:href='data:post.url'><data:post.title/></a>
<b:else/>
<data:post.title/>
</b:if>
</b:if>
<br/>
<span class='entrydate'><span class='style2'><data:post.dateHeader/></span></span>
</h2>
</b:if>
<div class='post-header-line-1'/>
<b:if cond='data:blog.pageType == "item"'>
<p><data:post.body/></p>
<b:else/>
<style>#fullpost {display:none;}</style>
<p><data:post.body/></p>
<span id='showlink'>
<p><a expr:onclick='"javascript:showFull(\"post-" + data:post.id + "\");"' href='javascript:void(0);'>Read More...</a></p>
</span>
<span id='hidelink' style='display:none'>
<p><a expr:onclick='"javascript:hideFull(\"post-" + data:post.id + "\");"' href='javascript:void(0);'>Summary only...</a></p>
</span>
<script type='text/javascript'>
checkFull("post-" + "<data:post.id/>");
</script>
</b:if>
<div style='clear: both;'/>
<!-- clear for photos floats -->
Any suggestion? At the moment the peekaboo function works but if we click read more link, it doesn't work.
I'm really frustrated, would greatly appreciate to have your help.
Thanks a lot Hans.
Finally Woken
I love this hack - it's so fast, but I have a tiny niggle that I'm wondering if anyone can help me resolve.
When I click 'read more' the whole post drops down just like it should. Also the page remains perfectly static (which I love). But when I click 'summary only' (which also works) the page kind of skips up slightly. It looks as though 'summary only' is linked to the top of the post and I was wondering if I can do something which will mean the page remains static both on 'read more AND 'summary'?
Also, if I do this when at the very top of my blog (ie the very first post). The page actually skips DOWN when I hit 'summary only', which looks even uglier.
Great hack, though.
I had the same error as many others ""Not well-formed code" etc and fixed it by deleting one of the /div tags at the bottom of the code that I copied from the site. I've replaced the "<>"s with "?"
?div style='clear: both;'/? ?!-- clear for photos floats --?
?/div?
?/div?
.... rest of template code ....
Just remove one of the ?/div?s
It fixed my issue.
I hope this might help someone else.
I have found that the 'home' button at the end of the post is missing. Is it something I did wrong or what.
That's a great hack for sure, but I wonder if there is a way to make it cleaner, e.g. not to link to a js located at an external server. Some people mentioned mootools would help (I don't know, not techy enough). And I've found this page, which seems to use only one little snippet of code to get things done: http://www.wassupbeb.com/2008/05/simple-expandable-collapsible-for.html
If you could apply that for your hack, that would be pretty awesome.
I'm still waiting for a clean hack to expand/collapse post summaries, comments and applying cool fade-in/fade-out effects, I mean it's Web 2.0 and all :)
Also: Stephen's tutorial on how to make peek-a-boo comments at http://singpolyma-tech.blogspot.com/ isn't very helpful because of his writing style, or/and Blogger team has modified the code since then. And many pages refer to a js snippet at googlepages which exceeded its bandwidth... That's the problem: the hacks are OLD, and linking to an external server means that someday it'll just quit working and you'll never know what hit you.
Oh, another thing I forgot:
the peek-a-boo posts hack skips to the post title when you collapse it again (annoying). But the peek-a-boo comments hack by Stephen here http://singpolyma-tech.blogspot.com/2006/10/comments-on-mainarchive-page-peek-boo.html?&tags=beta doesn't do that. Is there any way to fix that? Thanks!
I'm sure this isn't being actively supported anymore, but I've had a few issues with it, and it's been an uphill battle to get it to work.
First, when I got it installed initially, I couldn't get it to save, it was giving me an error that I was missing the close tag for the b:includable, the way to fix that was to add the update from your later post on making it automatically scroll back up, which doesn't make a lot of sense since it's just an extra div tag and bit of javascript, which shouldn't have had any effect all on whether the b:includable tag was closed or not, but oh well.
Then, every post had the Read more.. and it wasn't working on posts that did correctly have the span tags. That one I fixed by removing the code and saving and then re-adding it, which seems to have reset the unique id's that each post had, and everything seemed to work. It seems (and this is the reason I had started over with this code in the first place) that if you edit your html at all, the js seems to get confused, and you have to remove and re-add the code to get it to work again, I've tested this a few times, and it seems to work. Something as simple as changing the pixel width of the header will cause problems if you've already added the peek-a-boo code, requiring you to remove it and re-add it.
Now, the problem that I'm having is that my sidebar does not show up at all in Internet Explorer, but works fine in FireFox. Also, in IE, not only does the side bar not show up, but you can't scroll to the bottom of the page at all. It seems silly to use something that doesn't work in the dominant browser.
I can't figure out why this is happening at all. I've removed every other piece foreign code (like my statcounter code) from the page, and that hasn't helped either. It seems to be related specifically to the peek-a-boo post code somehow.
If I figure it out, I'll post again, but if you have any thoughts, I'd really appreciate it.
This is a great hack, and I really want it to work right!
Thanks.
fyrephlie.blogspot.com
AWSOME. It really works !!!
Thanks.
http://forotucuman.blogspot.com
Tucumán - Argentina
Hans,
I've tried to install your peekaboo on my site but each time, there's always an error message below my post title:-
expr:id='"post-" + data:post.id'>
and the full post won't expand as it should be. Advice me on this please.
it works perfect. thank you Hans. your hacks are always full proof and best explained :)
Thank you so much.
I like this better than the selective post hack..
Thanks for the share and keep up the good work...!
thanx a lot for ur tutorial!
Hi Hans,
I desperately want to include the peekaboo hack and have been trying all the possible ways of setting it up in my CSS but to no avail. I keep on getting the following error message: Your template could not be parsed as it is not well-formed. Please make sure all XML elements are closed properly.
XML error message: Element type "div" must be followed by either attribute specifications, ">" or "/>".
I am using thisaway template.
I will appreciate any help I can get.
Greetings from Windhoek, Namibia
Liza-Nel
Hans,
I tried to put a code in from Blogger Buster based on this code- but I want the ability to have the read more be a link that goes to the posts actual page instead of expanding. And of course have nothing there if it is a short post. Is this what your code does or can it?
Thanks,
Tessa
I have a strange quirk, having used and tested successfully the peek a boo more than once (thanks!) but now I've run into trouble with it.
The formatting is present and correct and works, but in the post:
Type your summary here.
code
Type the rest of your post here.
code
the lines of code between the instructions are missing though they flash up for a tenth of a second (?) and it'd be better if they were there for colleagues even though they can simply copy and paste over the lines of instruction.
That blank space becomes a bit more significant and is easily lost as reference on re-edits etc.
So not a great problem, but it's bugging me like mad and I really want to get the labels off from the bottom the actual posts and they won't go!
Anything simple I'm overlooking?
@Liza-Nel: I agree that this message of a missing closin-bracket can be quite frustrating! I have been there several times myself.
There is only one solution: check and double-check every line of code to see if here is a >-symbl missing at the end of a tag. Another reason might be a missing apostrophe. In some parts of the code you will see a single apostrophe ' followed by a double one ". Check them carefully. What I often do in such cases is to add the new code line by line, and saving the template after each line. That will help you to identify the culprit. Good luck!
@ Tessa: What it does now is that the code opens the post content inside the post, it does not 'jump' to the post page. I you are a biit of a javascript programmer you can easily rework my code to achieve that, but itwill no be exactly a peek-a-boo post.
@jrenn: I am not sure that I understand what your problem is. Please leave a link to a post where you actually have this problem.
PULL IT!!
A BIG BLOG!
Hello Hans,
I have tried a few different versions of this 'post summary' approach, but all seem to have one problem. They don't work if the contents within the 'span' elements have list elements like (ul or ol). It works for posts that don't have lists (bullet points).
Have you seen this problem? Is there any way to fix it?
Thanks.
Share your thoughts!
Feel free to post your questions, remarks and comments here. Moderation is set for this blog, so your comments will appear in due time.
Look who's linking here!
0 Backlinks point here