You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

咨询:google.translate.SectionalElement是否被移除?对应代码已失效

Google.translate.SectionalElement 已停止支持说明
  • Google确实移除了google.translate.SectionalElement接口,你提供的代码会因该接口不存在而无法运行:
function googleSectionalElementInit() {
    new google.translate.SectionalElement({
        sectionalNodeClassName: 'can-translate',
        controlNodeClassName: 'translation-control',
    }, 'google_sectional_element');
}
<script src="https://translate.google.com/translate_a/element.js?cb=googleSectionalElementInit"></script>
  • 目前Google没有发布专门的官方公告说明该功能停止支持,这类旧版翻译组件接口的变更通常不会单独通知,更多是随官方翻译组件的迭代更新被淘汰。

  • 若需要实现页面局部翻译功能,建议使用Google当前官方提供的翻译组件来替代。

内容的提问来源于stack exchange,提问作者Yuri

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.08.02 02:30:48