How to download a file with plus symbol(+) filename in IIS?
How to download a file with plus symbol(+) filename in IIS?
Original post link:https://www.cnblogs.com/markjiang7m2/p/10823844.html
Today I get a ticket with our client that they could not download a file with plus symbol(+) filename, such as the filename is a+b.xls.
I have a try and get the 404 code as below.

Firstly, I consider if the file is deleted on the server by someone, so I remote to the server and have a check. But...all going well. The file is here.
Then I search if someone has had this problem on the Internet. A lot of answers say that + is a specific symbol in browser. It should be transcoded into %2B.
So I add the js code as below and try again.
fileName=fileName.replaceAll("\\+","%2B");
window.location.href = conf.webAPIRoot + fileName;
But...it doesn't work for me.
In another answer found in https://forums.iis.net/t/1226370.aspx. It should be set in IIS. After the setting, I try again and it works for me.
Request Filtering -> Edit Feature Settings -> Allow Double Escaping


How to download a file with plus symbol(+) filename in IIS?的更多相关文章
- Unity3D发布WebPlayer时Failed to download data file解决方案
今天发布WebPlayer时, 发现直接打开html是可以正常运行的, 但是通过iis访问的话就会报错: Failed to download data file. 一开始以为是防火墙, 后来发现不是 ...
- Unity 3D本地公布WebPlayer版时"Failed to download data file"解决方式
watermark/2/text/aHR0cDovL2Jsb2cuY3Nkbi5uZXQvbGlzZW55YW5n/font/5a6L5L2T/fontsize/400/fill/I0JBQkFCMA ...
- Pikachu-File Inclusion, Unsafe file download & Unsafe file upload
Pikachu-File Inclusion, Unsafe file download & Unsafe file upload 文件包含漏洞 File Inclusion(文件包含漏洞)概 ...
- Download Excel file with Angular
源码连接(编写中) 用Angular下载后台返回的Excel文件,用Blob实现,引用FileSaver.js 后台C#代码: [WebMethod] public static byte[] Cal ...
- C# download big file
I had validated this.To download SSMS which is more than 500M+ static void Main(string[] args) { str ...
- how to download a file with Nodejs(without using third-party libraries)用node下载文件
创建HTTP GET请求并将其管理response到可写文件流中: var http = require('http'); var fs = require('fs'); var file = fs. ...
- Unity 3D本地发布WebPlayer版时Failed to download data file解决方案
遇到这个问题就是指Web服务器并没有支持这种*.unity3d文件类型.需要做的是在Web服务器中添加MIME类型: IIS 7 及以上版本: 在功能视图的IIS选项卡中: 双击打开MIME,选择添加 ...
- R包安装失败failed to download mirrors file
在R console中使用install.packages()来安装第三方包时,会出现这样的错误: 即使我们选择的是China的镜像也解决不了问题. 这时候,可以先试试用IE打开上图中黑底部分的URL ...
- curl download zip file
https://askubuntu.com/questions/285976/download-zip-file-with-curl-command
随机推荐
- BZOJ 3626 [LNOI2014]LCA:树剖 + 差分 + 离线【将深度转化成点权之和】
题目链接:http://www.lydsy.com/JudgeOnline/problem.php?id=3626 题意: 给出一个n个节点的有根树(编号为0到n-1,根节点为0,n <= 50 ...
- EF学习 开始操作02
历史版本和未来版本 本文介绍有关实体框架 (EF5) 最新版本的信息,其中大部分内容也适用于旧版本.有关完整版本列表以及各版本引入的功能的详细信息,请参阅 “版本历史”. “历史版本”页面包含实体框架 ...
- 单机版 RedisPoolUtil({基本操作封装工具类})【一】
<!--集成的RedisJAR--> <!--引入jedis需的jar包--> <dependency> <groupId>redis.clients& ...
- Tomcat翻译--Tomcat Web Application Deployment(Tomcat中部署web应用)
原文:http://tomcat.apache.org/tomcat-7.0-doc/deployer-howto.html Introduction(介绍) Deployment is the te ...
- linux命令学习笔记(12):more命令
more命令,功能类似 cat ,cat命令是整个文件的内容从上到下显示在屏幕上. more会以一页一页的显示方便 使用者逐页阅读,而最基本的指令就是按空白键(space)就往下一页显示,按 b 键就 ...
- jsp 自定义标签中的Function函数
在taglib中我们发现有一个标签叫做<function>,这次简单介绍<function>标签的基本用法,<function>标签可以做什么呢? 它可以让我们在j ...
- loj515贪心只能过样例
bitset练习题... 位运算真的是玄学... 一开始真的“只能过样例” 后来发现把左移写成了小于号 鬼知道我在想什么/手动微笑 loj第一题 #include<iostream> #i ...
- poj2420 A Star not a Tree? 模拟退火
题目大意: 给定n个点,求一个点,使其到这n个点的距离最小.(\(n \leq 100\)) 题解 模拟退火上 #include <cmath> #include <cstdio&g ...
- [JSOI 2015] 最大公约数
[题目链接] https://www.lydsy.com/JudgeOnline/problem.php?id=4488 [算法] 不妨首先枚举左端点 注意到对于任意一个正整数n , 其质因子个数是l ...
- P2056 采花
题目描述 萧芸斓是 Z国的公主,平时的一大爱好是采花. 今天天气晴朗,阳光明媚,公主清晨便去了皇宫中新建的花园采花.花园足够大,容纳了 n 朵花,花有 c 种颜色(用整数 1-c 表示) ,且花是排成 ...