為了改善您的使用體驗,本網站正在進行維護,部分功能暫時無法使用。若本站的文件無法解決您的問題,想要向社群發問的話,請到 Twitter 上的 @FirefoxSupport 或 Reddit 上的 /r/firefox 發問,我們的社群成員將很快會回覆您的疑問。

搜尋 Mozilla 技術支援網站

防止技術支援詐騙。我們絕對不會要求您撥打電話或發送簡訊,或是提供個人資訊。請用「回報濫用」功能回報可疑的行為。

了解更多

Google Translate Extension not working

  • 3 回覆
  • 1 有這個問題
  • 20 次檢視
  • 最近回覆由 cor-el

more options

Why again? After I reboot my pc and re-install firefox, I re-install back the Google Translate (GT) extension, it's not working like las time anymore.

It used to be I just press translate the entire website will auto translate..now after i reboot my pc and re-download latest Firefox, ur GT extension turned into shit. I add-on this extension 'To Google Translate by Juan Escobar' ...i use on the Chrome, no problem, I can translate the entire website. but I added back the same extension 'To Google Translate by Juan Escobar' in your Firefox it's different! WHY IS THAT? Pls view attachment. It used to be the same with firefox...what happened after the re-download to the latest version Firefox after rebooting my pc?

OS VERSION: WINDOWS 10, 64-bit CURRENT FIREFOX VERSION : 70.0.1 (64-bit)

Thanks,

Ally

Why again? After I reboot my pc and re-install firefox, I re-install back the Google Translate (GT) extension, it's not working like las time anymore. It used to be I just press translate the entire website will auto translate..now after i reboot my pc and re-download latest Firefox, ur GT extension turned into shit. I add-on this extension 'To Google Translate by Juan Escobar' ...i use on the Chrome, no problem, I can translate the entire website. but I added back the same extension 'To Google Translate by Juan Escobar' in your Firefox it's different! WHY IS THAT? Pls view attachment. It used to be the same with firefox...what happened after the re-download to the latest version Firefox after rebooting my pc? OS VERSION: WINDOWS 10, 64-bit CURRENT FIREFOX VERSION : 70.0.1 (64-bit) Thanks, Ally
附加的畫面擷圖

所有回覆 (3)

more options

Hi Ally, the way the first add-on works is by injecting the Google Translate "widget" into the page. This is a script hosted on Google's site and not included with the add-on.

Mozilla recently decided to block add-ons that inject outside scripts into page. This is because the Mozilla Add-ons team can't trust that such scripts will remain unchanged, potentially turning a safe add-on into a dangerous one.

If you need that "in page" translation to work, a partial workaround is to use one of the userscript extensions (Tampermonkey or Violentmonkey) and a userscript to inject Google's script. I posted such a userscript over here:

https://greasyfork.org/en/scripts/391935-inject-google-translate-widget

It doesn't work on every page because some sites block external scripts using Content Security Policy (CSP). (In that case, the inject menu items won't appear.)

more options

jscher2000,

Thanks for the help n sorry for my late respond...i basically given up hope for google translate to work like a charm in Firefox. I use FF for non-translation-needed sites. Google always a sneaky bastard.

Rgds, Ally

more options

Note that you can also use the Google Translate bookmarklet, what should work on all web pages. If you need a different language then replace google.com by the localized domain.

javascript:/*gten*/(function(){d=document;b=d.body;o=d.createElement('script');o.setAttribute('src','https://translate.google.com/translate_a/element.js?cb=googleTranslateElementInit');o.setAttribute('type','text/javascript');b.appendChild(o);v=b.insertBefore(d.createElement('div'),b.firstChild);v.id='google_translate_element';v.style.display='none';p=d.createElement('SCRIPT');p.text='function googleTranslateElementInit(){new google.translate.TranslateElement({pageLanguage:""},"google_translate_element");}';p.setAttribute('type','text/javascript');b.appendChild(p);})()

由 cor-el 於 修改