Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Configure IIS To Send “text/html” In Response for IE11

The updated version of Internet Explorer in Windows 8.1, IE11, has the following User Agent string as per this:

Mozilla/5.0 (Windows NT 6.3; Trident/7.0; rv:11.0) like Gecko

Our website is correctly setting the Content-Type in the response to "text/html" for all browsers except for when we use the IE11 UA. For browsers sending the IE11 UA, it's incorrectly sending "application/xhtml+xml" instead. All browsers send "text/html, application/xhtml+xml, */*" in the Accept header in the request.

Is there an IIS or ASP.NET web.config setting to allow "text/html" to be set for IE11 or a default? I'm not currently using any .browser files.

like image 287
Bullines Avatar asked May 21 '13 18:05

Bullines


1 Answers

The fix was to update our .browser file that defaults to "text/html, application/xhtml+xml", which it ended up doing for IE11.

like image 166
Bullines Avatar answered Nov 03 '22 01:11

Bullines