Berikut tampilannya :
lansung pada intinya, Inilah langkah-langkah untuk membuat related artikel :
1. Sebelum edit html, backup terlebih dahulu template
1. Sebelum edit html, backup terlebih dahulu template
2. Masuk ke template --> edit html dan cari Pasang kode berikut sebelum kode </head>
<script type='text/javascript'>
//<![CDATA[
/*
Related Post with Thumbnail & Summary 1.0 (http://www.ublogger.net)
*/
var relnojudul = 0;
var numpost = 10;
var numchars = 155;
var reljudul=new Array();var relurls=new Array();var relcuplikan=new Array();var relgambar=new Array();function saringtags(g,h){var e=g.split("<");for(var f=0;f<e.length;f++){if(e[f].indexOf(">")!=-1){e[f]=e[f].substring(e[f].indexOf(">")+1,e[f].length)}}e=e.join("");e=e.substring(0,h-1);return e}function relpostimgcuplik(h){for(var e=0;e<h.feed.entry.length;e++){var g=h.feed.entry[e];reljudul[relnojudul]=g.title.$t;postcontent="";if("content" in g){postcontent=g.content.$t}else{if("summary" in g){postcontent=g.summary.$t}}relcuplikan[relnojudul]=saringtags(postcontent,numchars);if("media$thumbnail" in g){postimg=g.media$thumbnail.url}else{postimg="http://1.bp.blogspot.com/-htG7vy9vIAA/Tp0KrMUdoWI/AAAAAAAABAU/e7XkFtErqsU/s1600/grey.GIF"}relgambar[relnojudul]=postimg;for(var f=0;f<g.link.length;f++){if(g.link[f].rel=="alternate"){relurls[relnojudul]=g.link[f].href;break}}relnojudul++}}function contains(a,e){for(var f=0;f<a.length;f++){if(a[f]==e){return true}}return false}function artikelterkait(){var v=new Array(0);var w=new Array(0);var x=new Array(0);var A=new Array(0);for(var u=0;u<relurls.length;u++){if(!contains(v,relurls[u])){v.length+=1;v[v.length-1]=relurls[u];w.length+=1;w[w.length-1]=reljudul[u];x.length+=1;x[x.length-1]=relcuplikan[u];A.length+=1;A[A.length-1]=relgambar[u]}}reljudul=w;relurls=v;relcuplikan=x;relgambar=A;for(var u=0;u<reljudul.length;u++){var B=Math.floor((reljudul.length-1)*Math.random());var i=reljudul[u];var s=relurls[u];var y=relcuplikan[u];var C=relgambar[u];reljudul[u]=reljudul[B];relurls[u]=relurls[B];relcuplikan[u]=relcuplikan[B];relgambar[u]=relgambar[B];reljudul[B]=i;relurls[B]=s;relcuplikan[B]=y;relgambar[B]=C}var r=0;var D=Math.floor((reljudul.length-1)*Math.random());var z=D;var q;var t=document.URL;while(r<numpost){if(relurls[D]!=t){q="<li class='news-title clearfix'>";q+="<a href='"+relurls[D]+"' rel='nofollow' target='_top' title='"+reljudul[D]+"'><div class='overlayb'></div><img src='"+relgambar[D]+"' /></a>";q+="<a class='relinkjdulx' href='"+relurls[D]+"' target='_top'>"+reljudul[D]+"</a>";q+="<span class='news-text'>"+relcuplikan[D]+"</span>";q+="</li>";document.write(q);r++;if(r==numpost){break}}if(D<reljudul.length-1){D++}else{D=0}if(D==z){break}}};
//]]>
</script>
<script type='text/javascript'>
//<![CDATA[
/*
Related Post with Thumbnail & Summary 1.0 (http://www.ublogger.net)
*/
var relnojudul = 0;
var numpost = 10;
var numchars = 155;
var reljudul=new Array();var relurls=new Array();var relcuplikan=new Array();var relgambar=new Array();function saringtags(g,h){var e=g.split("<");for(var f=0;f<e.length;f++){if(e[f].indexOf(">")!=-1){e[f]=e[f].substring(e[f].indexOf(">")+1,e[f].length)}}e=e.join("");e=e.substring(0,h-1);return e}function relpostimgcuplik(h){for(var e=0;e<h.feed.entry.length;e++){var g=h.feed.entry[e];reljudul[relnojudul]=g.title.$t;postcontent="";if("content" in g){postcontent=g.content.$t}else{if("summary" in g){postcontent=g.summary.$t}}relcuplikan[relnojudul]=saringtags(postcontent,numchars);if("media$thumbnail" in g){postimg=g.media$thumbnail.url}else{postimg="http://1.bp.blogspot.com/-htG7vy9vIAA/Tp0KrMUdoWI/AAAAAAAABAU/e7XkFtErqsU/s1600/grey.GIF"}relgambar[relnojudul]=postimg;for(var f=0;f<g.link.length;f++){if(g.link[f].rel=="alternate"){relurls[relnojudul]=g.link[f].href;break}}relnojudul++}}function contains(a,e){for(var f=0;f<a.length;f++){if(a[f]==e){return true}}return false}function artikelterkait(){var v=new Array(0);var w=new Array(0);var x=new Array(0);var A=new Array(0);for(var u=0;u<relurls.length;u++){if(!contains(v,relurls[u])){v.length+=1;v[v.length-1]=relurls[u];w.length+=1;w[w.length-1]=reljudul[u];x.length+=1;x[x.length-1]=relcuplikan[u];A.length+=1;A[A.length-1]=relgambar[u]}}reljudul=w;relurls=v;relcuplikan=x;relgambar=A;for(var u=0;u<reljudul.length;u++){var B=Math.floor((reljudul.length-1)*Math.random());var i=reljudul[u];var s=relurls[u];var y=relcuplikan[u];var C=relgambar[u];reljudul[u]=reljudul[B];relurls[u]=relurls[B];relcuplikan[u]=relcuplikan[B];relgambar[u]=relgambar[B];reljudul[B]=i;relurls[B]=s;relcuplikan[B]=y;relgambar[B]=C}var r=0;var D=Math.floor((reljudul.length-1)*Math.random());var z=D;var q;var t=document.URL;while(r<numpost){if(relurls[D]!=t){q="<li class='news-title clearfix'>";q+="<a href='"+relurls[D]+"' rel='nofollow' target='_top' title='"+reljudul[D]+"'><div class='overlayb'></div><img src='"+relgambar[D]+"' /></a>";q+="<a class='relinkjdulx' href='"+relurls[D]+"' target='_top'>"+reljudul[D]+"</a>";q+="<span class='news-text'>"+relcuplikan[D]+"</span>";q+="</li>";document.write(q);r++;if(r==numpost){break}}if(D<reljudul.length-1){D++}else{D=0}if(D==z){break}}};
//]]>
</script>
Keterangan :
var numpost = 10; --> 10 artikel terkait yang ditampilkan dan bisa diubah menurut selera
var numchars = 155; --> 155 karakter huruf yang ditampilkan sebagai summary dari artikel terkait dan bisa diubah
3. Masuk ke template editor cari kode </b:skin> dan masukkan kode berikut sebelum </b:skin> :
#related_posts{padding:5 5px 5px;overflow:hidden;display:inline;}#related_posts h4{padding:5px;font-size:8px;text-align:left}ul#relpost_img_sum{margin:0;padding:0;text-align:justify;display:inline;}ul#relpost_img_sum li{list-style:none;padding:5px;margin:0;width:600px;float:left;display:inline;}ul#relpost_img_sum li a{display:block}ul#relpost_img_sum li img{float:left;width:60px;height:60px;margin-right:5px;padding:2px;background-color:#1B1B1B;border:1px solid #cacaca}
ul#relpost_img_sum li a.relinkjdulx{display:block;height:30px;overflow:hidden;margin-bottom:3px;background-image:none;font-weight:bold;text-decoration:none;background:#FFFF99;}
sesuaikan kondisi berikut dengan template anda :
--> font size 8px,
--> dan width:600px ---> lebar template laman artikel
4. cari kode dan masukkan kode berikut setelah data:post.body :
<div id='related_posts'>
<h4>Related Posts</h4>
<b:loop values='data:post.labels' var='label'>
<script expr:src='"/feeds/posts/default/-/" + data:label.name + "?alt=json-in-script&callback=relpostimgcuplik&max-results=50"' type='text/javascript'/>
</b:loop>
<ul id='relpost_img_sum'>
<script type='text/javascript'>artikelterkait();</script>
</ul><a href=”http://www.ublogger.net”>.</a>
</div>
Label: modifikasi template
Responses
14 Respones to "Cara Membuat Artikel Terkait Paling Bagus"
Great article. Thanks for your great information, the content is quiet interesting. I will be waiting for your next post.
April 24, 2014 at 12:07 PM
This is an extremely well written article. I will make sure that I will bookmark it and open this page again to read this useful information provided by you.
May 15, 2014 at 4:47 PM
Hi, Really great effort. Everyone should read this article. Thanks for sharing.
May 16, 2014 at 2:16 PM
I have been browsing internet for more than three hours today since morning, yet I didn’t found any interesting article like this which provides knowledge.
June 13, 2014 at 4:18 PM
After looking at a few of the blog articles on your site, I seriously appreciate your way of writing it. I saved as a favorite it to my bookmark site list and
will be checking back in the near future.
July 15, 2014 at 1:14 PM
keren gan infonya salam semangat
thanks ya
December 18, 2014 at 5:05 PM
Amazing blog and very interesting stuff you got here! I definitely learned a lot from reading through some of your earlier posts as well and decided to drop a comment on this one!
November 27, 2015 at 3:20 PM
I really appreciate your professional approach. These are pieces of very useful information that will be of great use for me in future.
January 26, 2017 at 3:21 AM
Sudah lama ini bos, sekarang sudah ganti lagi trennya widgetnya
October 7, 2017 at 9:53 PM
Have you ever thought about publishing an ebook or guest authoring on other
websites? I have a blog based upon on the same ideas you discuss and would really like to have you share some
stories/information.
I know my subscribers would enjoy your work.
If you’re even remotely interested, feel free to send me an e mail. oh yeah visit Konveksi Tas Selempang
October 16, 2017 at 9:37 AM
Manta gan
November 14, 2018 at 9:34 PM
Amazing post,,,thanks
Vinyl Lantai Harga Murah
Toko Lantai Vinyl
Jual Lantai Vinyl
Distributor Lantai Vinyl
Vinyl Lantai Rumah Sakit
Wallpaper Dinding 3D
August 14, 2019 at 11:55 AM
Thanks infonya om
April 5, 2020 at 8:05 PM
Great article. Thanks for sharing great information.
Click on this link to join the active newspaper Whatsapp groups.
[Newspaper whatsapp group links]
December 16, 2020 at 12:07 PM
Post a Comment