Windows XP Windows 7 Windows 2003 Windows Vista Windows 綜合教學 Linux 系統教學
Windows 10 Windows 8 Windows 2008 Windows NT Windows Server 電腦軟體教學

Windows 8.1 IE11 相容性問題?用群組原則修正 User Agent 字串

編輯:Windows 8 系統介紹

Windows 8.1 內建 IE11,其 User Agent 字串變更為 Mozilla/5.0 (Windows NT 6.3; WOW64; Trident/7.0; rv:11.0) like Gecko,移除「MSIE」關鍵字,導致許多網銀、舊版網站誤判為 Firefox 而拒絕服務或版面錯亂。

根本解法:群組原則強制指定 UA 字串

  1. 按 Win + R 輸入 gpedit.msc 開啟「本機群組原則編輯器」。
  2. 依序展開:電腦設定 → 系統管理範本 → Windows 元件 → Internet Explorer。
  3. 右側雙擊「自訂使用者代理字串」。
  4. 選擇「已啟用」,輸入想要的版本字串,例如:
    MSIE 11.0(或 MSIE 10.0、MSIE 9.0、MSIE 8.0)。
  5. 按「確定」,關閉群組原則視窗。
  6. 重新開啟 IE11,按 F12 開發者工具驗證 UA 字串已生效。

群組原則啟用自訂 UA

輸入 MSIE 11.0 字串

優缺點比較

方法優點缺點
相容性檢視設定/加入網站清單針對單一網站逐站設定繁瑣
F12 開發者工具暫時變更 UA即時測試重開瀏覽器失效
群組原則修改 UA全域永久生效,一次設定所有網站受益需 Pro/Enterprise 版支援群組原則

注意:Windows 家用版無 gpedit.msc,可嘗試註冊表修改 HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_BROWSER_EMULATION 達到類似效果。

Copyright © Windows教程網 All Rights Reserved