开发者

PHP and a google translator API alternative

Since Google is going to pull the plug out of their translator API (by the end of this year), Is there someone who already f开发者_Go百科ound a good (free or $) alternative?


Try TranslateThis on http://translateth.is/...

Is very simple! To see the effects try this piece of code:

<!-- Begin TranslateThis Button -->

<div id="translate-this"><a style="width:180px;height:18px;display:block;" class="translate-this-button" href="http://translateth.is/">Translate</a></div>

<script type="text/javascript" src="http://x.translateth.is/translate-this.js"></script>
<script type="text/javascript">
TranslateThis();
</script>

<!-- End TranslateThis Button -->

Don't worry about the button aspect... You can customize it!


Google is offering and alternative to website translation. Its the GOOGLE WEB ELEMENTS, and some code from the google's web elements homepage itself for translation

<!-- Google Translate Element -->
<div id="google_translate_element" style="display:block"></div><script>
function googleTranslateElementInit() {
  new google.translate.TranslateElement({pageLanguage: "af"}, "google_translate_element");
};</script>

Other alternatives: Microsoft Translation Tools they offer HTTP, SOAP and SDK interfaces for integration.


If you need just language detection, there is free API:

http://detectlanguage.com

It produces JSON output, just like Google Translate.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜