Skip to content

MP4 Videos vom eigenen Webserver iPhone tauglich machenEnable your webserver to feed iPhone with MP4 videos

Ich verwende iPhone OS 3.x und hatte Probleme .mp4 Dateien direkt im Safari auf dem iPhone angezeigt zu bekommen. Ich habe verschiedenste Einstellungen beim Encodieren ausprobiert, aber immer wenn ich im iPhone Safari auf einen .mp4 Link auf meinem Webserver geklickt habe, kam die Fehlermeldung “Diese Datei kann nicht heruntergeladen / angezeigt werden”. Nach intensiver Suche im Internet fand ich dann Hinweise, dass es evtl. mit MIME types und der Apache Konfiguration zu tun haben könnte.

Lösung:

  1. Video für iPhone / iPod Touch encodieren (Compressor, Quicktime, Adobe Media Encoder, …)
  2. Video auf dem Gerät testen! (zur iTunes Library hinzufügen, aufs iPhone spielen und anschauen)
  3. Video auf den Webserver hochladen
  4. sicherstellen, dass folgende Zeile in der Apache Konfiguration bzw. in einer .htaccess Datei drin steht:
AddType video/mp4 mp4 mp4v mpg4 m4v

Das war’s, nun sollten .mp4 Videos vom Webserver als progressive Downloads (wieder) auf dem iPhone angezeigt werden können.

I’m using iPhone OS 3.x on my iPhone and recently i had problems to get my .mp4 files displayed in mobile Safari. I tried different settings for encoding the files but not a single one worked. When i clicked the link to the .mp4 file in mobile Safari, all i got was the “file can’t get downloaded” error. After some googling i found a clue that it might has something to do with MIME types and the apache server hosting the videos.

Solution:

  1. encode your videos for iPhone / iPod Touch (Compressor, Quicktime, Adobe Media Encoder, …)
  2. test them on the device (add the video to your iTunes library and upload it to your iPhone and watch it!)
  3. upload the video to your webserver
  4. make sure you have the following line in your apache config or in a .htaccess file in your directory on your webserver:
AddType video/mp4 mp4 mp4v mpg4 m4v

That’s it, now progressively watching .mp4 videos from your webserver on your iPhone should work (again).

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.