Sar*_* Pv 6 html5 internet-explorer-9 angularjs
嗨,我正在创建一个angularjs应用程序.我将$ locationProvider.html5Mode设为true.现在我没有#得到漂亮的网址.它在chrome和firefox中运行良好.但是当我试图在IE 9中打开它时,它会不断重新加载.
小智 11
坏消息.IE9不支持HTML5 History API.这就是角度html5Mode使用的.如果您需要在IE9上运行您的应用程序,您需要切换回或添加代码以检测历史API是否可用使用是或默认为哈希
function supports_history_api() {
return !!(window.history && history.pushState);
}
Run Code Online (Sandbox Code Playgroud)
我知道.愚蠢的IE.它应该死于痛苦的死亡.
| 归档时间: |
|
| 查看次数: |
8498 次 |
| 最近记录: |