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?的更多相关文章

  1. Unity3D发布WebPlayer时Failed to download data file解决方案

    今天发布WebPlayer时, 发现直接打开html是可以正常运行的, 但是通过iis访问的话就会报错: Failed to download data file. 一开始以为是防火墙, 后来发现不是 ...

  2. Unity 3D本地公布WebPlayer版时"Failed to download data file"解决方式

    watermark/2/text/aHR0cDovL2Jsb2cuY3Nkbi5uZXQvbGlzZW55YW5n/font/5a6L5L2T/fontsize/400/fill/I0JBQkFCMA ...

  3. Pikachu-File Inclusion, Unsafe file download & Unsafe file upload

    Pikachu-File Inclusion, Unsafe file download & Unsafe file upload 文件包含漏洞 File Inclusion(文件包含漏洞)概 ...

  4. Download Excel file with Angular

    源码连接(编写中) 用Angular下载后台返回的Excel文件,用Blob实现,引用FileSaver.js 后台C#代码: [WebMethod] public static byte[] Cal ...

  5. C# download big file

    I had validated this.To download SSMS which is more than 500M+ static void Main(string[] args) { str ...

  6. 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. ...

  7. Unity 3D本地发布WebPlayer版时Failed to download data file解决方案

    遇到这个问题就是指Web服务器并没有支持这种*.unity3d文件类型.需要做的是在Web服务器中添加MIME类型: IIS 7 及以上版本: 在功能视图的IIS选项卡中: 双击打开MIME,选择添加 ...

  8. R包安装失败failed to download mirrors file

    在R console中使用install.packages()来安装第三方包时,会出现这样的错误: 即使我们选择的是China的镜像也解决不了问题. 这时候,可以先试试用IE打开上图中黑底部分的URL ...

  9. curl download zip file

    https://askubuntu.com/questions/285976/download-zip-file-with-curl-command

随机推荐

  1. PHP继承中$this的问题

    在父类中的构造函数中使用$this , 这是$this指的是正在实例化的子类对象,不管是parent还是继承调用父类的构造函数. 如: class CompanyController extends ...

  2. .dhpcd导致cpu飙升问题

    因公司有业务服务器在阿里云上面,阿里云后台报警说,“有恶意程序在挖矿”,引起了高度重视,于是我登陆服务器进行排查. 登陆云服务器:系统centos7.5 第一步使用top查看资源情况. top 可以清 ...

  3. Hibernate - 配置c3p0

    <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE hibernate-configuratio ...

  4. torch7 安装中Missing dependencies for nn:moses >= 1错误解决办法

    Torch7.0安装步骤(默认安装路径是在home下): git clone https://github.com/torch/distro.git ~/torch --recursive cd ~/ ...

  5. ACM学习历程—HDU5422 Rikka with Graph(贪心)

    Problem Description As we know, Rikka is poor at math. Yuta is worrying about this situation, so he ...

  6. android开发 如何通过web服务器访问MYSQL数据库并且使其数据同步到android SQLite数据库?

    通过web服务器访问MYSQL数据库有以下几个过程: 1.在MySql下创建自己的数据库和自己的表单 2.连接数据库. 3.访问数据库 1.创建web工程 (服务器端) 在Myeclipse下新建一个 ...

  7. Percona Xtrabackup 备份MySQL 实例(转)

    老规矩,开场白,刚开始用mysqldump,备份100G+的数据库,再加上服务器繁忙,备份速度像蜗牛似的,于是寻找更高效的备份方法.网上都说用xtrabackup比较适合备份大的数据库,而且备份效率也 ...

  8. nginx实现防盗链配置方法介绍

    有些朋友觉得防盗链就是防止图片,其实有很多东西要进行防盗链了,下面我来介绍在nginx中实现防盗链配置方法有对图片防盗链与下载资源等. 防盗链配置 假设网站域名是 www.php100.com. 编辑 ...

  9. BarTender SDK 实现调用模板条码打印

    Demo:MyZebraPrint 基于BatTender .Net SDK 实现调用模板进行条码打印 有需要的朋友可以拿去研究下 在已经安装了BatTender10.1的电脑里测试通过. 下载地址: ...

  10. CentOS安装配置radius服务器

    1.安装 Yum install -y freeradius freeradius-mysql freeradius-utils 2.配置 1)修改 clients.conf # vi /usr/lo ...