How to Make a Table of Contents for Labels in Order
Ruanggoprek.web.id - This time we will discuss the table of contents which can be used to sort article pages in order from A to Z so that it will appear neatly arranged.
So this time the FHD site will write a tutorial, for example like this
Let's go straight to the tutorial
1. Enter Blogger, friends can write it in the post or page section,
2. Next, please copy the code below.
<div id="sitemap4">Loading....</div>
<script> //<![CDATA[
/* Blogger Sitemap Simple Title Only Sort By Title (Alphabetically) */
var start=1;var max=10000;var sitemap4Arr=new Array();function runSitemap4(){var scpt=document.createElement('script');scpt.src='/feeds/posts/default/-/Wawes?alt=json&callback=sitemap4&start-index='+start+'&max-results='+max;document.body.appendChild(scpt)} function sitemap4(root){var elem=document.getElementById('sitemap4');if(!elem)return;elem.innerHTML='';var feed=root.feed;if(feed.entry.length>0){for(var i=0;i<feed.entry.length;i++){var entry=feed.entry[i];var title=entry.title.$t;for(var j=0;j<entry.link.length;j++){if(entry.link[j].rel=="alternate"){var url=entry.link[j].href;if(url&&url.length>0&&title&&title.length>0){sitemap4Arr.push({'url':url,'judul':title})} break}}} if(feed.entry.length>=max){start+=max;runSitemap4()} else{var print='',a=sitemap4Arr.sort(function(a,b){return a.judul>b.judul?1:-1});for(var x=0;x<a.length;x++){print+='<li><a href=\"'+a[x].url+'\" title=\"'+a[x].judul+'\">'+a[x].judul+'</a></li>'} elem.innerHTML='<div class=\"judul\">Total Post: '+a.length+'</div><ol>'+print+'</ol>'}}} runSitemap4();
//]]> </script>
Notes:
1. /feeds/posts/default/-/ Wawes, Wawes is replaced with the label that you want
3. Save and see the results
Cover
That's the tutorial this time about How to Make a List of Contents Per Label in Order, hopefully it can be useful.

Post a Comment for "How to Make a Table of Contents for Labels in Order"