Memasang Emoticon Pada Kolom Komentar Di Blog
S ebuah emoticon/smiley kolom komentar di blog bisa di bilang penting karena, untuk menyatakan kondisi, sedih, senang, marah dsb dan itu juga bisa menjadi memperindah kolom komentar, sehingga tampak lebih hidup.
Sudah banyak tutorial cara memasang emoticon pada komentar di mbah google. Mungkin saya akan memasang emoticon yang sederhana tidak seperti yang lain. :D
Dan di bawah ini adalah contoh emoticon yang akan kita buat sob..
Simak dengan baik ya kalau mau kaya emoticon di atas :D
Yang pertama Blogger -> Templates -> Edit HTML, kemudian masukan CSS dibawah ini sebelum ]]></b:skin>
img.comment_emo {
height: auto !important;
vertical-align: middle !important;
width: auto !important;
border:0px !important;
}
Dan simpan kode dibawah tepat di atas </body>. <script type="text/javascript">
//<![CDATA[
/* Blogger Comments Emoticon
* by Kang Ismet
* Url:http://blog.kangismet.net
*/
ki = document.getElementById('comment-holder');
if (ki) {
zx = ki.getElementsByTagName("p");
for (i = 0; i < zx.length; i++) {
if (zx.item(i).getAttribute('CLASS') == 'comment-content') {
ki_emo = zx.item(i).innerHTML.replace(/:\)/gi, "<img src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiM26GD3L0rtBA8IRY7T3AqVYTBesN_Tt5SPp5te2BGp_xJuSHtzCBimdsbnVuGytxO3HV28zADGhXEds5VkcIm1XUxFYlWMXOANif8DrBZ9Zp1rhW-NSXPqUZK_IPu-YE-WJwCEbjcP6U/s1600/smile1.gif' alt='' class='comment_emo'/>");
ki_emo = ki_emo.replace(/\^_\^/gi, "<img src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhuVZObDd4xXDCbGL4Y7EjIRzvb1yQlf5S3VUySYI5-gohEM_8AO5aEsCYN4OEzO9uC9C8ve3Hta8G74AvRlY6hhwjjOdkNqZ-2wwlSFYIKmGCsx_UqrW_2Ot3S5nN_z1GxVaCdD1N5bgc/s1600/smile.gif' alt='' class='comment_emo'/>");
ki_emo = ki_emo.replace(/:-bd/gi, "<img src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi4bL7ljhQaV1tLcfK76PuKygR7X_vAMD9wkyEuDKwBV5wo7vqyH2Br4errsap1nZkDnaBo_uvc0pqWDMXX_wbvQts_aJqjLiZLf3wB5Rs4tHDZQ8oTimuFBP-wWDmkp1RGXUJAlC0Aubg/s1600/thumb.gif' alt='' class='comment_emo'/>");
ki_emo = ki_emo.replace(/:-d/gi, "<img src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjkHi2O61KL6tJkRk6aCYt0vTsUzI1atrcgT_lJhHCJAjsiM_6YrOXusUXpPspbcplLwkOMBcwHngBHPmhyphenhyphenSeKsaTED5QM270ZJjY6oKyswVnfvvJ_UvhKTpQ6mZZU1Kg9vdWwPtvzTz08/s1600/thumbsup.gif' alt='' class='comment_emo'/>");
ki_emo = ki_emo.replace(/@\@\,/gi, "<img src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiV0xsudXbpx-9cJioUGd99ZLHUaZq67orJNh-sUwkxdlI1X4SnFEJT1Z91VPhIbrD1oGrBfACyQkXROnS8UF9s7Hw4gSLd4WRR4JmUZykXyJFpqJ6INs2t1nxpaTsxUuvxyAZmvdlFlbU/s1600/rolleyes.gif' alt='' class='comment_emo'/>");
ki_emo = ki_emo.replace(/\\o\//gi, "<img src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhdhKQxvVBXZFlTGN7IeeUTDra85L6q1BXnL_Q2UmUpDduiIkGsj8NkKNWP_CKurqz6w1j1ur_kUUQSCy0trZtFJKxhgseHYCd877rytK13seL5yg0BM7Txj0wsPjyqEToKg-h3lLIhcjA/s1600/applause.gif' alt='' class='comment_emo'/>");
ki_emo = ki_emo.replace(/=\(/gi, "<img src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEifRu2F4ztFqTZ_MmWQUXOqoLb6LcGZlqXZzKeGBTk71bYP7hRu0kcT34jGjM08G0hYlroK9Otg-cLXkY9NPOozPSHgUHWBGdjJXSxv-yIW2_V7-abs9JjBOVR2pUXeQndHBM1AbNPWtFU/s1600/sadanimated.gif' alt='' class='comment_emo'/>");
ki_emo = ki_emo.replace(/:\(/gi, "<img src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjy7Wj3w_UM6q8uuVwvoakXn5sNZvjNmrd5ZQr9G5HsYIWby7mBmaQPBO9Xlq7HvMDha0z4XN0Z8b3lb_3lAYxfR5mwoBNymsAYNZrUJGw-yxAMSyJgw3AuEG8oV8t42kCUKsy9XCYX-Fo/s1600/sad.gif' alt='' class='comment_emo'/>");
ki_emo = ki_emo.replace(/\;\)/gi, "<img src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj4WOqLpfsgRE2lwIlgJFt4GZpF91nxf9SdeoYG1EF7pX3tYXN-QIn_VPjvwROeoEpOxx1NGzTd0SBhlr0wXxx8OJb3ZRmZVWtorG4JCu4GKFRtzlBltIZwr3OQE_BpSRQdainr6iQiyvM/s1600/wink.gif' alt='' class='comment_emo'/>");
ki_emo = ki_emo.replace(/:D/gi, "<img src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi6KlbDGvqLO-H3l4IIfKpBrP8SKJIzu_Xx84j1DTctTcCWVZm7iqnTk3stTHZ9DpT2XJqZ6fRDn6JBatmlBaBUeM8zrWpvyS2Fa_QjcurTKn2S2OUtwIFeU8zAP-CJLMadCrmEaSZb53I/s1600/icon_smile.gif='' class='comment_emo'/>");
ki_emo = ki_emo.replace(/=D/gi, "<img src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgdkWxDzVR8MneCipWFfHKlOaFKd8PN15w2wpSyueVqzyb2B9cJZAcNJTspHWDNtIQ0x6GLrPRDl63set4ToIjImrZet_De9r5yNQAlXG4M7uR2j02o1LBzdjuIAzurEUW0b6ukrpPol_U/s1600/hihi.gif' alt='' class='comment_emo'/>");
ki_emo = ki_emo.replace(/:\P/gi, "<img src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjx8ctVMWzK23iVibkK7KOomuH7-3vgmSTBQfOCWHRt7eaxGZd8u3OohOuziZ359346alh8R0uM0FOHLmga2U_QNAO2es2k4srkCH5gr2QRZiJCOkcu8wxwi1ykLwy2DohLEbj5KP7spPU/s1600/wee.gif' alt='' class='comment_emo'/>");
ki_emo = ki_emo.replace(/:\p/gi, "<img src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjx8ctVMWzK23iVibkK7KOomuH7-3vgmSTBQfOCWHRt7eaxGZd8u3OohOuziZ359346alh8R0uM0FOHLmga2U_QNAO2es2k4srkCH5gr2QRZiJCOkcu8wxwi1ykLwy2DohLEbj5KP7spPU/s1600/wee.gif' alt='' class='comment_emo'/>");
zx.item(i).innerHTML = ki_emo;
}
}
}
//]]>
</script>
Metode Penulisan
Metode penulisannya standar saja seperti penulisan emot di bawah ini. Ingat emoticon ini hanya buat komentar default saja.
:) ^_^ :-d :-bd @.@ :(
Selamat mencobanya sobat. ^_^
keren gan makasih
ReplyDeleteKeren gan ! Berguna banget artikelnya buat para blogger !:D
ReplyDeleteoooh bigitu toh caranya, saya coba pasang di blog saya mas
ReplyDeletewah ijin comot gan
ReplyDeleteBlognya sudah asaya follow atas nama SimBalisme no 7
ReplyDeletefollback blog saya simbalisme.blogspot.com
thx sobat
izin pasang gan
ReplyDeleteAne sudah punya ni gan btw thanks infonya
ReplyDeleteWah, ini cocok sekali untuk diterapin di blog saya gan ...
ReplyDeleteMakasih atas tutorialnya :)
ribet juga ya gan
ReplyDeletehaduh css lagi css lagi
ReplyDeletetakutnya blog saya tambah berat agan :3
waahh asik nih biar tambah unik kelihatannya,,, ytapi kayaknya kok ribet bgt gitu yaaa
ReplyDelete7 Hal Yang Membuat Kita Jadi Pelupa
Terlalu banyak protein di usia pertengahan 'seburuk merokok'
Tricks Identifying People Lying