Preventing AAC Spew
As much as I love to hear everyone’s GarageBand compositions (and I’m not being sarcastic—I do), I am getting a little weary of clicking on links to AAC files, only to have Safari dutifully display 4 MB of incomprehensible binary data because the web server isn’t savvy to the AAC MIME type. So, as a public service, here are instructions that will help at least some people prevent that from happening to their listeners:
- Make sure your web host allows you to use .htaccess files (which they probably won’t unless they’re running Apache).
- In the root directory of your site (not the root directory of your shell account, mind you—we’re talking about the one that contains the main page someone sees when they come to your site), create a file called “.htaccess”. If one already exists, simply open it.
- In this file, add a line like the following:
- There is no step 4. Safari should now correctly recognize AAC files served from your site as audio.
AddType audio/mp4 .m4a