Windows Server 2008 + IIS7: .ogg files can not be played

7,019

Add the OGG MIME type in your web.config. Something like:

<configuration>
    <system.webServer>
        <staticContent>
            <mimeMap fileExtension=".m4v" mimeType="video/m4v" />
            <mimeMap fileExtension=".ogg" mimeType="audio/ogg" />
            <mimeMap fileExtension=".oga" mimeType="audio/ogg" />
            <mimeMap fileExtension=".ogv" mimeType="video/ogg" />
            <mimeMap fileExtension=".webm" mimeType="video/webm"/>
        </staticContent>
    </system.webServer>
</configuration>

See:

Share:
7,019
greatromul
Author by

greatromul

I push keys...

Updated on September 18, 2022

Comments

  • greatromul
    greatromul almost 2 years

    I have the strange trouble. There are .mp3 and .ogg files in the folder of web application in my server (IIS7.5, Windows Server 2008 R2). Web application has flash player. It can play .mp3 only, but it don't play .ogg-files. Same web application in other server works fine. Have anybody idea? Thanks.

  • Daniel Cheung
    Daniel Cheung about 8 years
    I want to ask a question regarding your config. .ogg can be audio or video, how would you write to support that?