ERR_RESPONSE_HEADERS_MULTIPLE_CONTENT_DISPOSITION error in Chrome – How to fix How to address a nasty HTTP error that you could get in Google Chrome browser when you're handling files with commas in their filename

How to clear Google Chrome Redirect Cache for a single URL

Today we were called to fix a strange issue that was happening to one of our colleagues when trying to download a PDF file from one of our Document Management Systems. The error was related to a single file and sounded like this:

This page isn’t working

 

(the website) sent an invalid response.
ERR_RESPONSE_HEADERS_MULTIPLE_CONTENT_DISPOSITION

ERR_RESPONSE_HEADERS_MULTIPLE_CONTENT_DISPOSITION error in Chrome - How to fix

That sounded quite strange, especially considering the fact that a lot of other files – same extension, same size and so on – was working fine.

We found the solution rather quickly by finding this StackOverflow thread, which luckily enough pointed us to the right direction. The issue was related to a single “comma” in the filename as defined in the Content-Definition header, which was programmatically defined in the back-end code:

It’s worth noting that, even if the mentioned SO topic was related to Django, it’s definitely an universal issue: we were getting it with ASP.NET C# as well.

Anyway, the proper solution was to encompass the filename with double quotes, thus avoiding HTTP header mismatches:

 

That’s pretty much about it. I hope that this quick fix will help those who’ll be stuck with this issue as well!

 

About Ryan

IT Project Manager, Web Interface Architect and Lead Developer for many high-traffic web sites & services hosted in Italy and Europe. Since 2010 it's also a lead designer for many App and games for Android, iOS and Windows Phone mobile devices for a number of italian companies. Microsoft MVP for Development Technologies since 2018.

View all posts by Ryan

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.