Τρίτη 30 Μαρτίου 2010

FLAGS TRANSLATOR

Ένας φίλος και αναγνώστης του Locus Blogus, ο Βασίλης, ζήτησε να μάθει πως γίνεται να βάλουμε μεταφραστή (translator) o οποίος να απεικονίζεται μόνο με σημαίες και να μην είναι όπως αυτός της Convey This που έχω και στην αριστερή στήλη του παρόντος ιστολογίου. Δεν είναι κάτι δύσκολο. Στην ουσία μιλάμε για ένα gadget το οποίο μπαίνει όπως και όλα τα υπόλοιπα σε ένα blog. Η διαδικασία είναι γνωστή: Μπαίνουμε στο blogspot λογαριασμό μας, από τον πανόπτη πάμε διάταξη, προσθήκη gadget και επιλέγουμε HTML/JavaScript. Εκεί κάνουμε αντιγραφή επικόλληση (copy - paste) τον παρακάτω κώδικα και πατάμε αποθήκευση (save). Ο μεταφραστής είανι ο translator της Google και στο ιστολόγιο μας θα φαίνεται όπως το παρακάτω screenshot. Καλή επιτυχία.

Ο κώδικας είναι ο εξής:

<style> .google_translate img { filter:alphaundefinedopacity=100); -moz-opacity: 1.0; opacity: 1.0; border:0; } .google_translate:hover img { filter:alphaundefinedopacity=30); -moz-opacity: 0.30; opacity: 0.30; border:0; } .google_translatextra:hover img { filter:alphaundefinedopacity=0.30); -moz-opacity: 0.30; opacity: 0.30; border:0; } </style> <div> <a class="google_translate" href="#" target="_blank" rel="nofollow" title="English" onclick="window.openundefined'http://translate.google.com/translate?u='+encodeURIComponentundefinedlocation.href)+'&langpair=auto%7Cen&hl=en'); return false;"><img alt="English" border="0" align="absbottom" title="English" height="24" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjpp_v2zXV6X3cKnzLCHB5H-KOhOgxMAqPh34CVXqciGhA_J5AzMXI3j5YvEY3OSrbSoTiiGHdarqf7C-KwiSqhIFa8X5KqRzUGWRe0N8eL6XKkOfrftf-9rxyJseO3yjB70rn0ZQIPGfc/s200/United+KingdomundefinedGreat+Britain).png" style="cursor: pointer;margin-right:8px" width="24" /></a> <a class="google_translate" href="#" target="_blank" rel="nofollow" title="French" onclick="window.openundefined'http://translate.google.com/translate?u='+encodeURIComponentundefinedlocation.href)+'&langpair=auto%7Cfr&hl=en'); return false;"><img alt="French" border="0" align="absbottom" title="French" height="24" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEggcVcVgFNpGPto6dv2mSEcz5Qt59iSEdZKmyQ5z0NzNg_VF0xK0QtYWNSKx9p7DN3E4kjsbM1PMeW1QGNmTKGk_EFKhYJBOsIBjcOEYc9aVwj1v3qixELIfRBSV7k2uwOS4-FTXtRHECk/s200/France.png" style="cursor: pointer;margin-right:8px" width="24" /></a> <a class="google_translate" href="#" target="_blank" rel="nofollow" title="German" onclick="window.openundefined'http://translate.google.com/translate?u='+encodeURIComponentundefinedlocation.href)+'&langpair=auto%7Cde&hl=en'); return false;"><img alt="German" border="0" align="absbottom" title="German" height="24" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjSm70088tQASygDJ0Q0IQENkF2PA1-LK6PMgWcQwuoPbw-UGvbl1IXhsWLejadh8MCvbs2x2kLUuR4hcrLLGHsCo28jCAvdT2ejo5QR1P_lejg7UABHCNYtYpuzNGradzG27Yl3OUaWDM/s200/Germany.png" style="cursor: pointer;margin-right:8px" width="24" /></a> <a class="google_translate" href="#" target="_blank" rel="nofollow" title="Spain" onclick="window.openundefined'http://translate.google.com/translate?u='+encodeURIComponentundefinedlocation.href)+'&langpair=auto%7Ces&hl=en'); return false;"><img alt="Spain" border="0" align="absbottom" title="Spain" height="24" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjuG2AQNj8CvwH6Fesuv0mbJXsreE5TE2O-A5YDfJWUNyU6_XUK8laWyHZexevqNfqAsqGOsJEneCnAzvbK60UvoKQdUie4xBy9MvdZbTw7ScEQpRDsviw0P7hHBRwp7VTBem6OindnIoE/s200/Spain.png" style="cursor: pointer;margin-right:8px" width="24" /></a> <a class="google_translate" href="#" target="_blank" rel="nofollow" title="Italian" onclick="window.openundefined'http://translate.google.com/translate?u='+encodeURIComponentundefinedlocation.href)+'&langpair=auto%7Cit&hl=en'); return false;"><img alt="Italian" border="0" align="absbottom" title="Italian" height="24" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEisVKb-ELBBiTcVyz-NfpSamheYv2gXBPgBWOU6NSDnXXad4Gja4__elm9mq5lUEw0WpEAGEUjDYDNV1krdjqqUwIHLVIDTbUXT_ypBXeS-vi8c3IcDJ5RqjIrK1pqbcgiikOXzsCfynFo/s200/Italy.png" style="cursor: pointer;margin-right:8px" width="24" /></a> <a class="google_translate" href="#" target="_blank" rel="nofollow" title="Dutch" onclick="window.openundefined'http://translate.google.com/translate?u='+encodeURIComponentundefinedlocation.href)+'&langpair=auto%7Cnl&hl=en'); return false;"><img alt="Dutch" border="0" align="absbottom" title="Dutch" height="24" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjsWvm8lXdepVYbwE872-Jh8kmWjm_tOp_WqMZUEgyLjcGAtfWmCoF6QA7DZqV6BUr6-l_6vzB1xUVi4LQCFzUpPBu9ChKUdBunjhhrDacN7y5ALlUAP62UUEMHysNhoL9_VcapCuCQ6Zw/s200/Netherlands.png" style="cursor: pointer;margin-right:8px" width="24" /></a> <a class="google_translate" href="#" target="_blank" rel="nofollow" title="Russian" onclick="window.openundefined'http://translate.google.com/translate?u='+encodeURIComponentundefinedlocation.href)+'&langpair=auto%7Cru&hl=en'); return false;"><img alt="Russian" border="0" align="absbottom" title="Russian" height="24" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjREEUr80b_Z9xl6lhTSBtZBjGBmcH_19ChpctDaJzBAMNsCboXYz7fm9WzUbiTAY_B0jhoQHObiNggt0aYuOVMxfrS8Y2F7W-8eX8NqkB95ajrvrIQ3deuSRK_AyEe8XpaiIr4zYlj7Gc/s200/Russian+Federation.png" style="cursor: pointer;margin-right:8px" width="24" /></a> <a class="google_translate" href="#" target="_blank" rel="nofollow" title="Portuguese" onclick="window.openundefined'http://translate.google.com/translate?u='+encodeURIComponentundefinedlocation.href)+'&langpair=auto%7Cpt&hl=en'); return false;"><img alt="Portuguese" border="0" align="absbottom" title="Portuguese" height="24" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjpYxPR4jp1Jhn_40UVqHHBWJH1oMehysQidtkOUggD95LVeyhyphenhyphenTiRt29CGCu6Bs7dCmobVjmeKLLTrXP5h9nVDF4LCFfARIDsROkEZvCetfo30wVrgdKz6GGv32S_cwuihIlJLVcdPzDM/s200/Brazil.png" style="cursor: pointer;margin-right:8px" width="24" /></a> <a class="google_translate" href="#" target="_blank" rel="nofollow" title="Japanese" onclick="window.openundefined'http://translate.google.com/translate?u='+encodeURIComponentundefinedlocation.href)+'&langpair=auto%7Cja&hl=en'); return false;"><img alt="Japanese" border="0" align="absbottom" title="Japanese" height="24" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgGewcMM4k2Ug5kt61DDrdrlcfs1F2vRUrrjizmTUc1hdPgsze7hQjJ1DVQVHnsdHZC-F_UDxt71qawy30d6T4JsPqDI2KPUib1YdTM4MisjBAZu4iza04FkhXu50uIhrGB2ugftyRpLtM/s200/Japan.png" style="cursor: pointer;margin-right:8px" width="24" /></a> <a class="google_translate" href="#" target="_blank" rel="nofollow" title="Korean" onclick="window.openundefined'http://translate.google.com/translate?u='+encodeURIComponentundefinedlocation.href)+'&langpair=auto%7Cko&hl=en'); return false;"><img alt="Korean" border="0" align="absbottom" title="Korean" height="24" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgDuipaAn5YzABiX1vCHAdPcb2Yet_cuyOUIDNlLhkxm0V7xlvQDpcTkI1U-dHAWTxEd4ZIhqfFf9RVGmFB3gYRoUlIry6UCN58Hemy78WgaPt-n-bBUcnBfH2kpyP2ILjYSVi3PDs1L2U/s200/South+Korea.png" style="cursor: pointer;margin-right:8px" width="24" /></a> <a class="google_translate" href="#" target="_blank" rel="nofollow" title="Arabic" onclick="window.openundefined'http://translate.google.com/translate?u='+encodeURIComponentundefinedlocation.href)+'&langpair=auto%7Car&hl=en'); return false;"><img alt="Arabic" border="0" align="absbottom" title="Arabic" height="24" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEijg0cEjKmYXHRD3sYKWVv6r0yKza21CVY0UgiXUe4v9kwukrwiXGV2AGhzv2gzffyNTcD72thVwcJbtseze4MSjCSXn7NFaVNkSFepinday-Kh7xZrOerqmGff-uULOEjcNqMoEvY0jB4/s200/Saudi+Arabia.png" style="cursor: pointer;margin-right:8px" width="24" /></a> <a class="google_translate" href="#" target="_blank" rel="nofollow" title="Chinese Simplified" onclick="window.openundefined'http://translate.google.com/translate?u='+encodeURIComponentundefinedlocation.href)+'&langpair=auto%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/AVvXsEjuYpmpS2lTdFFMni5IrKSPkLNjlgdM531y4lD0jKpr9rzWiGd0cfcz-MmWh9U9X0VZC12GxBvMgEQdo4zg6b1qTbpppQItP0mWPJNK8aAiZ0u7TyLKoF9NaBgVZqYRKaTUTbBLgrggiGA/s200/China.png" style="cursor: pointer;margin-right:8px" width="24" /></a></div>
back to top