Sign up for PayPal and start accepting credit card payments instantly.

How To Create a List of Contents According to Label Blog

.

Table of Contents is very necessary for a blog so that visitors can easily google search our blog. Blogger itself has not provided a list of widgets for other content and widget Archieves Labels.

But we can use the widget Labels as an aid to create our own list of contents based on a label or category. By using javascript, we can do this.


Steps that must be done is:

1. Edit the script in advance in accordance with the label and the name of your blog.
2. Log in to your Blogger Dashboard
3. Create a new post.
4. Copy-parse the script


<table border="0" cellspacing="20"><tbody>
<tr><td valign="top" width="45%">

<center style="color: lime;"><span style="font-size: x-large;">LabelTitle1</span></center>
<script style="text/javascript">
function showrecentposts(json) {
for (var i = 0; i < numposts; i++) {
// get entry i from feed
var entry = json.feed.entry[i];
// get the posttitle
var posttitle = entry.title.$t;
// get the post url
if (i == json.feed.entry.length) break;
for (var k = 0; k < entry.link.length; k++) {
if (entry.link[k].rel == 'alternate') {
posturl = entry.link[k].href;
break;
}
}
document.write('<li><a href="'+ posturl + '">'+ posttitle + '</a>'+ '<br>');
}
}
</script><br />
<p>Articles :</p><ul><script style="text/javascript">
var numposts=100;
var numchars=100;
</script>
<script

src="http://BLOGTITLE.blogspot.com/feeds/posts/default/-/LabelTitle1?alt=json-in-script&callback=showrecentposts"></script>
</ul>
</td> <td valign="top" width="45%">

<center style="color: lime;"><span style="font-size: x-large;">LabelTitle2</span></center>
<script style="text/javascript">
function showrecentposts(json) {
for (var i = 0; i < numposts; i++) {
// get entry i from feed
var entry = json.feed.entry[i];
// get the posttitle
var posttitle = entry.title.$t;
// get the post url
if (i == json.feed.entry.length) break;
for (var k = 0; k < entry.link.length; k++) {
if (entry.link[k].rel == 'alternate') {
posturl = entry.link[k].href;
break;
}
}
document.write('<li><a href="'+ posturl + '">'+ posttitle + '</a>'+ '<br>');
}
}
</script><br />
<p>Articles :</p><ul><script style="text/javascript">
var numposts=100;
var numchars=100;
</script>
<script src="http://BLOGTITLE.blogspot.com/feeds/posts/default/-/LabelTitle2?alt=json-in-script&callback=showrecentposts"></script>
</ul>
</td> </tr>
</tbody></table>

<table border="0" cellspacing="20"><tbody>
<tr><td valign="top" width="45%">

<center style="color: lime;"><span style="font-size: x-large;">LabelTitle3</span></center>
<script style="text/javascript">
function showrecentposts(json) {
for (var i = 0; i < numposts; i++) {
// get entry i from feed
var entry = json.feed.entry[i];
// get the posttitle
var posttitle = entry.title.$t;
// get the post url
if (i == json.feed.entry.length) break;
for (var k = 0; k < entry.link.length; k++) {
if (entry.link[k].rel == 'alternate') {
posturl = entry.link[k].href;
break;
}
}
document.write('<li><a href="'+ posturl + '">'+ posttitle + '</a>'+ '<br>');
}
}
</script><br />
<p>Articles :</p><ul><script style="text/javascript">
var numposts=100;
var numchars=100;
</script>
<script

src="http://BLOGTITLE.blogspot.com/feeds/posts/default/-/LabelTitle3?alt=json-in-script&callback=showrecentposts"></script>
</ul>
</td> <td valign="top" width="45%">

<center style="color: lime;"><span style="font-size: x-large;">LabelTitle4</span></center>
<script style="text/javascript">
function showrecentposts(json) {
for (var i = 0; i < numposts; i++) {
// get entry i from feed
var entry = json.feed.entry[i];
// get the posttitle
var posttitle = entry.title.$t;
// get the post url
if (i == json.feed.entry.length) break;
for (var k = 0; k < entry.link.length; k++) {
if (entry.link[k].rel == 'alternate') {
posturl = entry.link[k].href;
break;
}
}
document.write('<li><a href="'+ posturl + '">'+ posttitle + '</a>'+ '<br>');
}
}
</script><br />
<p>Articles :</p><ul><script style="text/javascript">
var numposts=100;
var numchars=100;
</script>
<script src="http://BLOGTITLE.blogspot.com/feeds/posts/default/-/LabelTitle4?alt=json-in-script&callback=showrecentposts"></script>
</ul>
</td> </tr>
</tbody></table>

<table border="0" cellspacing="20"><tbody>
<tr><td valign="top" width="45%">

<center style="color: lime;"><span style="font-size: x-large;">LabelTitle5</span></center>
<script style="text/javascript">
function showrecentposts(json) {
for (var i = 0; i < numposts; i++) {
// get entry i from feed
var entry = json.feed.entry[i];
// get the posttitle
var posttitle = entry.title.$t;
// get the post url
if (i == json.feed.entry.length) break;
for (var k = 0; k < entry.link.length; k++) {
if (entry.link[k].rel == 'alternate') {
posturl = entry.link[k].href;
break;
}
}
document.write('<li><a href="'+ posturl + '">'+ posttitle + '</a>'+ '<br>');
}
}
</script><br />
<p>Articles :</p><ul><script style="text/javascript">
var numposts=100;
var numchars=100;
</script>
<script

src="http://BLOGTITLE.blogspot.com/feeds/posts/default/-/LabelTitle5?alt=json-in-script&callback=showrecentposts"></script>
</ul>
</td> <td valign="top" width="45%">

<center style="color: lime;"><span style="font-size: x-large;">LabelTitle6</span></center>
<script style="text/javascript">
function showrecentposts(json) {
for (var i = 0; i < numposts; i++) {
// get entry i from feed
var entry = json.feed.entry[i];
// get the posttitle
var posttitle = entry.title.$t;
// get the post url
if (i == json.feed.entry.length) break;
for (var k = 0; k < entry.link.length; k++) {
if (entry.link[k].rel == 'alternate') {
posturl = entry.link[k].href;
break;
}
}
document.write('<li><a href="'+ posturl + '">'+ posttitle + '</a>'+ '<br>');
}
}
</script><br />
<p>Articles :</p><ul><script style="text/javascript">
var numposts=100;
var numchars=100;
</script>
<script src="http://BLOGTITLE.blogspot.com/feeds/posts/default/-/LabelTitle6?alt=json-in-script&callback=showrecentposts"></script>
</ul>
</td> </tr>
</tbody></table>

<table border="0" cellspacing="20"><tbody>
<tr><td valign="top" width="45%">

<center style="color: lime;"><span style="font-size: x-large;">LabelTitle7</span></center>
<script style="text/javascript">
function showrecentposts(json) {
for (var i = 0; i < numposts; i++) {
// get entry i from feed
var entry = json.feed.entry[i];
// get the posttitle
var posttitle = entry.title.$t;
// get the post url
if (i == json.feed.entry.length) break;
for (var k = 0; k < entry.link.length; k++) {
if (entry.link[k].rel == 'alternate') {
posturl = entry.link[k].href;
break;
}
}
document.write('<li><a href="'+ posturl + '">'+ posttitle + '</a>'+ '<br>');
}
}
</script><br />
<p>Articles :</p><ul><script style="text/javascript">
var numposts=100;
var numchars=100;
</script>
<script src="http://BLOGTITLE.blogspot.com/feeds/posts/default/-/LabelTitle7?alt=json-in-script&callback=showrecentposts"></script>
</ul>
</td> <td valign="top" width="45%">

<center style="color: lime;"><span style="font-size: x-large;">LabelTitle8</span></center>
<script style="text/javascript">
function showrecentposts(json) {
for (var i = 0; i < numposts; i++) {
// get entry i from feed
var entry = json.feed.entry[i];
// get the posttitle
var posttitle = entry.title.$t;
// get the post url
if (i == json.feed.entry.length) break;
for (var k = 0; k < entry.link.length; k++) {
if (entry.link[k].rel == 'alternate') {
posturl = entry.link[k].href;
break;
}
}
document.write('<li><a href="'+ posturl + '">'+ posttitle + '</a>'+ '<br>');
}
}
</script><br />
<p>Articles :</p><ul><script style="text/javascript">
var numposts=100;
var numchars=100;
</script>
<script

src="http://BLOGTITLE.blogspot.com/feeds/posts/default/-/LabelTitle8?alt=js

on-in-script&callback=showrecentposts"></script>
</ul>
</td> </tr>
</tbody></table>

<div style='text-align:center; font-size:80%'>"Widget by: <a href='http://sulthanyusuf.blogspot.com/2009/12/how-to-create-a-list-of-contents-according-to-label-blog.html'>BLOG SulthanYusuf ™"</a></div>



5.In the bottom row code, replace BLOGTITLE.blogspot.com with your blog name as the name and replace blog.blogspot.com
6.LableTitle1, LableTitle2, LableTitle3, etc. to label your post will be made a list of contents.
7.If your post in one label more than a hundred, then you stay up the settings on numposts variable.
8.Then publish your post and try to open your blog then your contents will look like this; click here to review


-



RELATED POST :


4 comments:

Rizkyzone said...

mengamankan pertamax..... scriptnya panjang bgt sob.... ok deh Rizky save dulu, oy ada award buat sahabat jikalau berkenan silakan d ambil disini

Utilize My Words said...

nice post

masterGOmaster said...

boleh juga nih sob tutorialnya, kapan kapan aja aku praktekan.makasih :)

Adin said...

wah bener mantab ente bos....scriptnya luarr biasa panjangnya he he he dapat ilmu lh nih gw tank's ya..udh mau datang ke blog ku ditunggu tukar link nya ya?

:)) ;)) ;;) :D ;) :p :(( :) :( :X =(( :-o :-/ :-* :| 8-} :)] ~x( :-t b-( :-L x( =))

Post a Comment

Your comment will appear soon, so do not embarrass yourself with a spam comment!

 

Followers

Recent POST

adsenseCAMP | KumpulBLOGGER

Sharing About Tips And Tricks of Blogging And Chatting! is proudly powered by o-om.com | Modif by BLOG SulthanYusuf ™