如何制作一个php或html页面,您输入一两个单词,它输出翻译后的文本


How to make a php or html page that you feed a word or two and it outputs the translated text

基本上我对这个完美版本的看法是:在我的SMF论坛上制作一个php/html页面,在其中放入一些代码,页面url将类似www.myforums.com/translate-EnFr-hello%20world,当你打开它时,它会显示一个空白的白色页面,上面写着"Bonjour le monde"。我可以找到提供输入的其他方法,但我希望输出与我指定的一致。

谁能告诉我从哪里开始/如果可能的话?

你可以使用Google Translate API: https://cloud.google.com/translate/docs/