ASPNetFAQ.com: What is ASP.NET?

Technology posts on ASP.NET, IIS, Windows (+ a little Linux), Cloud Servers, Hosting, and more!
  • Blog Home
Search the site...

IIS7 Mime Mappings

Tweet
Share
0 Shares

For very good reasons, not all extensions are recognized by IIS by default and may return a 404 error when trying to access them from your site. If you have need to add more extensions to be “allowed” – for example if you have embedded font files – you have a few different options.

One method is to add the new mapping in the MIME Mappings module of the IIS7 Manager which you can run and use locally, or you can use the IIS7 Manager for Remote Administration to connect to your site remotely and manage this feature. Once connected, the link below shows where to find this module and make the required change.

http://www.iis.net/ConfigReference/system.webServer/staticContent/mimeMap

That same link gives a little bit of information about managing the mime mappings via your site config file, but not a lot of detail. The link below gives additional information and even a sample web.config file that someone specifically used to manage their mappings.

http://stackoverflow.com/questions/3461329/iis-ignores-system-webserver-staticcontent-section

Some web hosts also have control panels that allow you to manage the mime mappings for your web site. If so, it should be fine to use that too. Any of these three methods should accomplish the same thing.

Once you decide where to manage the mapping, you need to make sure you set it up properly. Different file types have different requirements so you may need to do a little research on your own to determine the exact mapping text. Here’s one sample showing how to map embedded .woff font files: http://www.dirigodev.com/blog/404-errors-in-IIS7-for-embedded-woff-font-files/

I hope this saves you a little time and frustration. Happy hosting!

More from my site

  • Orchard: Custom Content in Sub-FoldersOrchard: Custom Content in Sub-Folders
  • Resolving a “There is a duplicate ‘system.web.extensions/scripting/scriptResourceHandler’ section defined” ErrorResolving a “There is a duplicate ‘system.web.extensions/scripting/scriptResourceHandler’ section defined” Error
  • PUT/POST/DELETE Verb Errors On SitePUT/POST/DELETE Verb Errors On Site
  • Log Parser: Pulling Valuable Data From IIS LogsLog Parser: Pulling Valuable Data From IIS Logs
  • Linking spam sent through shared IIS SMTP server to a userLinking spam sent through shared IIS SMTP server to a user
Tweet
Share
0 Shares
ASP.NET, cytanium, Development/Coding, Hosting, IIS, OrcsWeb, System Administration, tip

Comments are closed.

Proverbs 19:20

"Get all the advice and instruction you can, so you will be wise the rest of your life."

A Note On WordPress Hosting

Our main focus is of course .NET, but with a mix of Linux, virtualization, and other technologies. But if you're really looking for the best WordPress hosting specifically, read my WordPress host review to save yourself hassle AND money!




Recent Posts

  • What makes good web hosting?
  • jQuery Mobile C# ASP.NET and N5 Networks Software Repository
  • Open Source Bug Tracking Software and the Orchard Project
  • ASP.NET Development with Dreamweaver MX: Visual QuickPro Guide
  • Kendo UI Sample, ASP.NET Ajax Tutorial & More

Tags

ASP.NET Automation centos CMS css cytanium Development/Coding Email gmail Hosting htaccess http https IIS javascript Learning Linux logparser MySQL nginx openssl OrcsWeb performance PowerShell redirect RHEL security server SherWeb smtp SQL/Databases ssl System Administration telnet terminal tip Troubleshooting Ubuntu virtualization Visual Studio web farm web hosting Windows windows server Wordpress

Categories

  • ASP.net development
  • Development/Coding
  • Hosting
  • IIS (Internet Information Services)
  • SQL/Databases
  • System Administration
  • Virtualization
(c) ASPNETFAQ.com