使用uploadify的时候,firebug与chrom的console报get 404问题的解决办法
来源:互联网 发布:一起看电影的软件 编辑:程序博客网 时间:2024/06/05 23:49
首先上错误图:
这个错误是:当你打开包含有uploadify的插件的页面的时候,就会出现
之前,一直以为是我拦截器的问题,然后断点一步步的跟踪,没有发现任何问题。然后发现,打开其他页面都不报错,就只有包含有uploadify插件的页面才会报这个错。于是将错误定位。
然后上官网查询,看是否配置的问题,有说是struts2上传大小限制的问题,经过排查也不对。(大小问题报404是上传的时候报,并不是打开的时候报错)
最后终于在《Uploadify v3 bug. Unecessary request when there is no button_image_url set.》中找到问题所在。
原来问题的症结在于SWFUpload,这个是Uploadify调用供支持Flash上传用的,但是其没有对button_image_url进行判断,导致如果button_image_url为空的话就默认请求了当前根路径,修改的方法也比较简单,加个判断即可:
1、首先打开你文件中的jquery.uploadify.js,
2、通过搜索找到:
<span style="font-size:14px;color:#FF0000;">this.settings.button_image_url=SWFUpload.completeURL(this.settings.button_image_url);</span>这一行代码。
3、用:
<span style="font-size:14px;color:#FF0000;">if(this.settings.button_image_url!=""){ this.settings.button_image_url=SWFUpload.completeURL(this.setting s.button_image_url); }</span><span style="font-size:14px;">替换它。</span>
0 0
- 使用uploadify的时候,firebug与chrom的console报get 404问题的解决办法
- 使用uploadify的时候,firebug与chrom的console报get 404问题的解决办法
- FireBug的console使用
- firebug中的console.log()使用注意的问题
- firebug中的console.log()使用注意的问题
- firebug的console
- 使用git的时候报错解决办法
- firebug 的 console用法简要
- 使用firebug的console和commandline方便调试
- 使用Firebug的console导致IE提示对象未定义错误
- firefox、chrom浏览器使用swfupload上传文件出现404错误的解决办法
- firebug中的console常用的方法
- 解决firebug报“illegal character"错误的问题
- chrom的成功
- Chrom 的线程模型
- Chrom 的线程模型
- chrom的收藏夹导入
- firebug的使用
- Android Drawable Resource学习(三)、NinePatchDrawable和NinePatch图片的制作
- ORACLE行列互转方法汇总
- ubuntu java开发环境初学搭建
- 纯手工制作—Android原生手势锁
- DDE的工作原理
- 使用uploadify的时候,firebug与chrom的console报get 404问题的解决办法
- Linux下安装jdk过程
- SQL锁表语句
- iOS小功能备忘----实现文字复制到粘贴板
- 定时执行备份mysql
- emqttd java代码测试
- 奶牛专题2:奶牛晒衣服
- xUtils简介
- Android Drawable Resource学习(四)、LayerDrawable