I have set up a simple ring server with a file server
(ns scratch.basic-test
(:use [ring.middleware.file :only [wrap-file]]
[ring.middleware.file-info :only [wrap-file-info]])
(:require [ring.adapter.jetty :as jetty]))
(defn naked-handler [request]
{:status 200
:headers {"Content-Type" "text/html"}
:body (str request})
(defonce server
(run-jetty (-> #'naked-handler
(wrap-file "resources/public")
wrap-file-info)
{:port 8890 :join? false}))
I have test.mp4 and video.html in the resources/public directory.
video.html references the mp4 file:
...blah...
<video id="my_video_1" controls>
<source src="test.mp4" type='video/mp4'>
</video>
...blah...
when I open up http://server-ip-address:8890/video.html in safari, firefox and ie it works fine
however, when i open it up on the ipad, it does not.. a black cannot-play-rectangle is displayed instead.
when i put the same files in an apache server and open up video.html on the ipad the video plays perfectly....
what is going on?