Sabtu, 10 Maret 2012

Cara Pasang Widget Google Translet di Blog

Cara Pasang Widget Google Translet di Blog
Sesuai dengan namanya. Widget ini berfungsi untuk menerjemahkan bahasa yang satu ke bahasa yang lain. Dengan memasang widget ini, maka pengunjung yang berasal dari negara lain juga bisa menikmati konten diblog anda. Selain itu, anda juga bisa memanfaatkan widget ini untuk belajar bahasa asing lho. Menarikkan?
Google Translate di seTiap Posting
5 hal yang harus dilakukan setelah membuat blog baru?
Sebenarnya  google translate ini sudah pernah saya bahas pada beberapa waktu yang lalu. Namun karena widget ini sudah mengalami perubahan yaitu menggunakan icon-icon bendera sehingga tampilannya menjadi lebih menarik.

Contohnya seperti ini yang dibuat oleh mad tomatoe




dan ini yang dibuat oleh kang rohman




Oleh sebab itu, pada postingan ini saya ingin membahas kembali dengan menyajikan widget buatan saya sendiri. Seperti yang dibawah ini









Widget ini saya buat dengan mengganti icon bendera yang berbentuk seperti pin dan diberi sedikit efek shadow sehingga hasilnya menjadi seperti diatas. Semoga tidak terlalu mengecewakan. 
sengihnampakgigi

Bagi anda yang tertarik, silahkan copy kode dibawah ini.


Untuk Google Translate 2 baris. Gunakan kode dibawah ini:






<style>
.translate img {
filter:alpha(opacity=100);
-moz-opacity: 1.0;
opacity: 1.0;
border:0;
padding-left:0px;
}
.translate:hover img {
filter:alpha(opacity=50);
-moz-opacity: 0.50;
opacity: 0.50;
border:0;
}
</style>

<div style="text-align:center">

<a class="translate" href="#" target="_blank" rel="nofollow" title="English" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Cen&hl=en'); return false;"><img alt="English" border="0" align="absbottom" title="English" height="24" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjSud7VFEQziO4lNS4B9_Xk8sCQgV1RKvtNsGwvfEqtte_jmVkXv6pFvb7z6MMlZMueZk_cjJfGlcCaX0TYVy2WQ6tFe-BxuwG8XD4Y6jZHdcRvPgrt7bB2b4g3iGk4HYnoC37CSXrtPWON/s144/uk-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>

<a class="translate" href="#" target="_blank" rel="nofollow" title="French" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Cfr&hl=en'); return false;"><img alt="French" border="0" align="absbottom" title="French" height="24" src="
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgKPSZQfPUZMkGAjGKufV6XstiQ6F8QUwFNjs-QgtHdgYk3TbcajEWaGffmTpdB-MgB7TmxLamNDvZp2Hq9dQODjFmIqEk7rNNYndpS4qRU-_XmlYbfMTlSP1kXuvesoTwa4a_lcg1HE62l/s144/france-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>

<a class="translate" href="#" target="_blank" rel="nofollow" title="German" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Cde&hl=en'); return false;"><img alt="German" border="0" align="absbottom" title="German" height="24" src="
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgb6xxyhEvhFqtc-77et-aVjIyMMnR2f9f9RwXvqSjizf9RAoOWgvAUzwBWJ9n8e6UDwldqc-JK7EK4alV9k6EpnAJhmiOg6xHYfVPFqGoqtGPYlFnrIQEmZjdK4eGFo50AsM5dGo8_K6lN/s144/german-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>

<a class="translate" href="#" target="_blank" rel="nofollow" title="Spain" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Ces&hl=en'); return false;"><img alt="Spain" border="0" align="absbottom" title="Spain" height="24" src="
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj96NRQNjwv89TZoCkbawGjp_KDUY3oEvzVEmsDyiGg1iOA7T9RFoaUHP3wjio0TBUfWrVq8_UmcTAhOUx4j41W4ZpSKU8b76kcDdo5jj5o8BYzoveK4imREfvzl8zHVNUb6A-FmfYSHXD9/s144/spain-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>

<a class="translate" href="#" target="_blank" rel="nofollow" title="
Italian" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Cit&hl=en'); return false;"><img alt="Italian" border="0" align="absbottom" title="Italian" height="24" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjbN63GVSs3LSebuEhtWzpyjO6JGnINPesyia9haVSg56YR27xgR6Y33dPQ24VCGW8xzyOSsFgxlpUJS01NITdnaNVV2yxWjpQJ9HJeStvtxZJbhVqWsdNUIJJ0mV_j0ZkQZhM3HEE1iW1U/s144/italy-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>

<a class="translate" href="#" target="_blank" rel="nofollow" title="Dutch" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Cnl&hl=en'); return false;"><img alt="Dutch" border="0" align="absbottom" title="Dutch" height="24" src="
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgYfLGyxSZXEIb5RPOlYefer-IKUh7pwoN7GUc8DHnHsF3oTjeAMmTVJuHnAohBxq3gVtdbOXhm2BJey3ekh7CzCgOrOjI8Qb5VspJ6AW1Blqbbc5voqqigvaBM6fr7ZC14vErqbgjNX-VQ/s144/dutch-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>
<br/><br/>
<a class="translate" href="#" target="_blank" rel="nofollow" title="Russian" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Cru&hl=en'); return false;"><img alt="Russian" border="0" align="absbottom" title="Russian" height="24" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjwgUeOZ_N6seKZ5kjoKf-nt0wESvYy4ZlqigPgVNckknJBTHPB7n4GS2GkssAN_DKns0A6NEwt4Z9tg66PWapttv7bQsrDkamzfns8WnfWXLN_1zQ-G4E_Co7ats1vK2ik7pc0NNMfmFH7/s144/russian-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>

<a class="translate" href="#" target="_blank" rel="nofollow" title="Brazil" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Cpt&hl=en'); return false;"><img alt="Brazil" border="0" align="absbottom" title="Brazilian" height="24" src="
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjOWsWE3MaCYzOMWd8NfJWBgNVbjj_-YbaLtJ4IFLVORtg8jLS_RrsmbXEjNtbyOccQ7_Rkktao4RGU_q5Dexyt8N-fL4YU6tbJPQtcRwghhWsXsBlLgTQMzaunTpGzMTUkftRQUoSrnSNB/s144/brazil-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>

<a class="translate" href="#" target="_blank" rel="nofollow" title="Japanese" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Cja&hl=en'); return false;"><img alt="Japanese" border="0" align="absbottom" title="Japanese" height="24" src="
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi4tixTTQ1TVWtzZgwgXs1Oa3lhNtu1AOhD_ooZahkEeoAbPgRVYgYFSfCSTM5kCy1YLiqC0uz_QDgM_p7bpqDjbenEK730kVBhRN1pxkMVma52C37KBtD5_Xzec1lEmQ1SJM4AVbYqypgj/s144/japan-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>

<a class="translate" href="#" target="_blank" rel="nofollow" title="Korean" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Cko&hl=en'); return false;"><img alt="Korean" border="0" align="absbottom" title="Korean" height="24" src="
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh0Rxo-t8Ru6IV_TBs_S4BAJ03lkp2mSybm_hVoVcOx2_Vhmov8eqwnGNNWLo0bm00-mZI6DOZQ9wPq2B4MhEg-ZmwIvC2EUQdTrfPXb6oHQgqTQIcJYOQDiPzzdgvQq08iUAzTs4Y92dnr/s144/korean-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>

<a class="translate" href="#" target="_blank" rel="nofollow" title="Arabic" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Car&hl=en'); return false;"><img alt="Arabic" border="0" align="absbottom" title="Arabic" height="24" src="
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEinWXDKlYoaICDhHTWrlq9lvvN07G0XY-GXxOpKzikgIGsiNYzv0ip3T1E6eMsPDhfzfM6EpGiuZ-SAjjwwopLD4VlG3uUnAjokmWpfi-goQxTXfT-ChKSrZ89GWejRfkuK_vdnkkG_wxa2/s144/arab-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>

<a class="translate" href="#" target="_blank" rel="nofollow" title="Chinese Simplified" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Czh-CN&hl=en'); return false;"><img alt="Chinese Simplified" border="0" align="absbottom" title="Chinese Simplified" height="24" src="
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiUvVPxQQl-iwSM9_Xk7GQkNFcLZ-wLRoPyplfKGDINvUYfeV6dJ-GU3dJXb-dWRu8rPORloklCG4MBNoB37iF9pvsw0ARwFL0wR8oLCBRilhRgPC1C7BfTnrRoWSz2cQwdtinyN_u1FAaP/s144/china-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>

<div style="font-size:9px; padding:8px 0px 0px 0px">

<a href="http://www.hermanblog.com/2009/03/memasang-widget-google-translate-pada.html" target="_blank">Translate Widget</a> by Google
</div></div>


Untuk Google Translate 3 baris. Gunakan kode dibawah ini:

google translate widget








<style>
.translate img {
filter:alpha(opacity=100);
-moz-opacity: 1.0;
opacity: 1.0;
border:0;
padding-left:0px;
}
.translate:hover img {
filter:alpha(opacity=50);
-moz-opacity: 0.50;
opacity: 0.50;
border:0;
}
</style>

<div style="text-align:center">

<a class="translate" href="#" target="_blank" rel="nofollow" title="English" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Cen&hl=en'); return false;"><img alt="English" border="0" align="absbottom" title="English" height="24" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjSud7VFEQziO4lNS4B9_Xk8sCQgV1RKvtNsGwvfEqtte_jmVkXv6pFvb7z6MMlZMueZk_cjJfGlcCaX0TYVy2WQ6tFe-BxuwG8XD4Y6jZHdcRvPgrt7bB2b4g3iGk4HYnoC37CSXrtPWON/s144/uk-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>

<a class="translate" href="#" target="_blank" rel="nofollow" title="French" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Cfr&hl=en'); return false;"><img alt="French" border="0" align="absbottom" title="French" height="24" src="
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgKPSZQfPUZMkGAjGKufV6XstiQ6F8QUwFNjs-QgtHdgYk3TbcajEWaGffmTpdB-MgB7TmxLamNDvZp2Hq9dQODjFmIqEk7rNNYndpS4qRU-_XmlYbfMTlSP1kXuvesoTwa4a_lcg1HE62l/s144/france-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>

<a class="translate" href="#" target="_blank" rel="nofollow" title="German" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Cde&hl=en'); return false;"><img alt="German" border="0" align="absbottom" title="German" height="24" src="
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgb6xxyhEvhFqtc-77et-aVjIyMMnR2f9f9RwXvqSjizf9RAoOWgvAUzwBWJ9n8e6UDwldqc-JK7EK4alV9k6EpnAJhmiOg6xHYfVPFqGoqtGPYlFnrIQEmZjdK4eGFo50AsM5dGo8_K6lN/s144/german-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>

<a class="translate" href="#" target="_blank" rel="nofollow" title="Spain" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Ces&hl=en'); return false;"><img alt="Spain" border="0" align="absbottom" title="Spain" height="24" src="
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj96NRQNjwv89TZoCkbawGjp_KDUY3oEvzVEmsDyiGg1iOA7T9RFoaUHP3wjio0TBUfWrVq8_UmcTAhOUx4j41W4ZpSKU8b76kcDdo5jj5o8BYzoveK4imREfvzl8zHVNUb6A-FmfYSHXD9/s144/spain-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>
<br/><br/>
<a class="translate" href="#" target="_blank" rel="nofollow" title="Italian" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Cit&hl=en'); return false;"><img alt="Italian" border="0" align="absbottom" title="Italian" height="24" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjbN63GVSs3LSebuEhtWzpyjO6JGnINPesyia9haVSg56YR27xgR6Y33dPQ24VCGW8xzyOSsFgxlpUJS01NITdnaNVV2yxWjpQJ9HJeStvtxZJbhVqWsdNUIJJ0mV_j0ZkQZhM3HEE1iW1U/s144/italy-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>

<a class="translate" href="#" target="_blank" rel="nofollow" title="Dutch" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Cnl&hl=en'); return false;"><img alt="Dutch" border="0" align="absbottom" title="Dutch" height="24" src="
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgYfLGyxSZXEIb5RPOlYefer-IKUh7pwoN7GUc8DHnHsF3oTjeAMmTVJuHnAohBxq3gVtdbOXhm2BJey3ekh7CzCgOrOjI8Qb5VspJ6AW1Blqbbc5voqqigvaBM6fr7ZC14vErqbgjNX-VQ/s144/dutch-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>

<a class="translate" href="#" target="_blank" rel="nofollow" title="Russian" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Cru&hl=en'); return false;"><img alt="Russian" border="0" align="absbottom" title="Russian" height="24" src="
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjwgUeOZ_N6seKZ5kjoKf-nt0wESvYy4ZlqigPgVNckknJBTHPB7n4GS2GkssAN_DKns0A6NEwt4Z9tg66PWapttv7bQsrDkamzfns8WnfWXLN_1zQ-G4E_Co7ats1vK2ik7pc0NNMfmFH7/s144/russian-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>

<a class="translate" href="#" target="_blank" rel="nofollow" title="Brazil" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Cpt&hl=en'); return false;"><img alt="Brazil" border="0" align="absbottom" title="Brazilian" height="24" src="
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjOWsWE3MaCYzOMWd8NfJWBgNVbjj_-YbaLtJ4IFLVORtg8jLS_RrsmbXEjNtbyOccQ7_Rkktao4RGU_q5Dexyt8N-fL4YU6tbJPQtcRwghhWsXsBlLgTQMzaunTpGzMTUkftRQUoSrnSNB/s144/brazil-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>
<br/><br/>
<a class="translate" href="#" target="_blank" rel="nofollow" title="Japanese" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Cja&hl=en'); return false;"><img alt="Japanese" border="0" align="absbottom" title="Japanese" height="24" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi4tixTTQ1TVWtzZgwgXs1Oa3lhNtu1AOhD_ooZahkEeoAbPgRVYgYFSfCSTM5kCy1YLiqC0uz_QDgM_p7bpqDjbenEK730kVBhRN1pxkMVma52C37KBtD5_Xzec1lEmQ1SJM4AVbYqypgj/s144/japan-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>

<a class="translate" href="#" target="_blank" rel="nofollow" title="Korean" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Cko&hl=en'); return false;"><img alt="Korean" border="0" align="absbottom" title="Korean" height="24" src="
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh0Rxo-t8Ru6IV_TBs_S4BAJ03lkp2mSybm_hVoVcOx2_Vhmov8eqwnGNNWLo0bm00-mZI6DOZQ9wPq2B4MhEg-ZmwIvC2EUQdTrfPXb6oHQgqTQIcJYOQDiPzzdgvQq08iUAzTs4Y92dnr/s144/korean-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>

<a class="translate" href="#" target="_blank" rel="nofollow" title="Arabic" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Car&hl=en'); return false;"><img alt="Arabic" border="0" align="absbottom" title="Arabic" height="24" src="
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEinWXDKlYoaICDhHTWrlq9lvvN07G0XY-GXxOpKzikgIGsiNYzv0ip3T1E6eMsPDhfzfM6EpGiuZ-SAjjwwopLD4VlG3uUnAjokmWpfi-goQxTXfT-ChKSrZ89GWejRfkuK_vdnkkG_wxa2/s144/arab-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>

<a class="translate" href="#" target="_blank" rel="nofollow" title="Chinese Simplified" onclick="window.open('http://translate.google.com/translate?u='+encodeURIComponent(location.href)+'&langpair=id%7Czh-CN&hl=en'); return false;"><img alt="Chinese Simplified" border="0" align="absbottom" title="Chinese Simplified" height="24" src="
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiUvVPxQQl-iwSM9_Xk7GQkNFcLZ-wLRoPyplfKGDINvUYfeV6dJ-GU3dJXb-dWRu8rPORloklCG4MBNoB37iF9pvsw0ARwFL0wR8oLCBRilhRgPC1C7BfTnrRoWSz2cQwdtinyN_u1FAaP/s144/china-flag.png" style="cursor: pointer;margin-right:8px" width="24"/></a>

<div style="font-size:9px; padding:8px 0px 0px 0px">

<a href="http://www.hermanblog.com/2009/03/memasang-widget-google-translate-pada.html" target="_blank">Translate Widget</a> by Google
</div></div>


1. Kalau sudah, buka kotak 
HTML/ javascript lalu pastekan kodenya kedalam kotak.

2. Klik 
Save. Selesai. Silahkan lihat hasilnya.


Jika anda merasa letaknya kurang pas dengan kolom sidebar anda. Anda bisa menyesuaikan jaraknya dengan mengganti nilai 
0 pada padding-left. Semakin tinggi nilainya semakin lebar jaraknya. Dan jika anda ingin mengganti icon benderanya dengan icon lain. Silahkan ganti tulisan bewarna merah dengan alamat url icon anda.

Sumber Artikel ini : http://www.hermanblog.com/2009/03/memasang-widget-google-translate-pada.html