不开webServer让chrome能读取本地json等文件
来源:互联网 发布:sql insert into例子 编辑:程序博客网 时间:2024/05/29 17:24
PS:一些测试页面偶尔会加载本地的json文件,没有开web server一般不能访问…不一定每次都要开nginx或apache解决, chrome可以加启动参数“allow-file-access-from-files”
Using –disable-web-security switch is quite dangerous! Why disable security at all while you can just allow XMLHttpRequest to access files from other files using –allow-file-access-from-files switch?
Before using these commands be sure to end all running instances of Chrome.
On Windows:
chrome.exe –allow-file-access-from-files
On Mac:
open /Applications/Google\ Chrome.app/ --args --allow-file-access-from-files
Discussions of this “feature” of Chrome:
https://code.google.com/p/chromium/issues/detail?id=37586,
https://code.google.com/p/chromium/issues/detail?id=47416,
http://productforums.google.com/forum/#!topic/chrome/v177zA6LCKU
原文参考
http://www.chrome-allow-file-access-from-file.com/
- 不开webServer让chrome能读取本地json等文件
- 读取本地json文件
- win7如何本地让IIS服务器可以读取json文件
- 从本地读取json文件
- JavaScript读取本地json文件
- JQuery读取本地Json文件
- JQuery读取本地JSON文件
- JQuery读取本地JSON文件
- JQuery读取本地json文件
- angular4读取本地json文件
- iOS 读取本地JSON文件
- ajax读取本地json文件
- 读取本地JSON文件并显示
- android 读取本地的json文件
- java 读取本地的json文件
- cocos2dx LUA 读取本地JSON文件
- 从本地JSON文件中读取数据
- 读取本地JSON文件并显示
- STL系列之十 全排列
- 【.Net码农】腾迅股票数据接口 http/javascript
- HDU 5137 How Many Maos Does the Guanxi Worth(枚举+dijkstra) 2014ICPC 广州站现场赛
- 标量 ,数组,hash 引用
- mysql 的 decode 函数实现
- 不开webServer让chrome能读取本地json等文件
- Code Snippets我居然才知道的好东西
- 二维数组查找
- IOS 自定义Cell的3种方式
- java学习笔记:1.有关java类加载顺序的栗子
- 深信服软件开发面试---体无完肤
- 数据从oracle转换到mysql
- hpuoj 1698: 海域, 冰山, 战舰 【dfs】
- spring使用注解的简单例子