aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLoïc Hoguin <[email protected]>2013-01-22 17:19:39 +0100
committerLoïc Hoguin <[email protected]>2013-01-22 17:19:39 +0100
commitca98a86b30ca62e706a05c7cf83018471dce0fe3 (patch)
treee7cd50ea4092b4814d128201ba72b2243e1cb2d7
parent166761483d9c511766fbfe6d4e501c3826f949d9 (diff)
downloadcowboy-ca98a86b30ca62e706a05c7cf83018471dce0fe3.tar.gz
cowboy-ca98a86b30ca62e706a05c7cf83018471dce0fe3.tar.bz2
cowboy-ca98a86b30ca62e706a05c7cf83018471dce0fe3.zip
Add HTML5 Video Example to the static example
-rw-r--r--examples/static/README.md5
-rw-r--r--examples/static/priv/small.mp4bin0 -> 383631 bytes
-rw-r--r--examples/static/priv/small.ogvbin0 -> 872453 bytes
-rw-r--r--examples/static/priv/video.html11
-rwxr-xr-xexamples/static/start.sh3
5 files changed, 18 insertions, 1 deletions
diff --git a/examples/static/README.md b/examples/static/README.md
index ef46312..78f5338 100644
--- a/examples/static/README.md
+++ b/examples/static/README.md
@@ -42,3 +42,8 @@ $ curl -sLO http://localhost:8080/test.txt
$ cat test.txt
If you read this then the static file server works!
```
+
+HTML5 Video Example
+-------------------
+
+Open http://localhost:8080/video.html in your favorite browser.
diff --git a/examples/static/priv/small.mp4 b/examples/static/priv/small.mp4
new file mode 100644
index 0000000..1fc4788
--- /dev/null
+++ b/examples/static/priv/small.mp4
Binary files differ
diff --git a/examples/static/priv/small.ogv b/examples/static/priv/small.ogv
new file mode 100644
index 0000000..6409d6e
--- /dev/null
+++ b/examples/static/priv/small.ogv
Binary files differ
diff --git a/examples/static/priv/video.html b/examples/static/priv/video.html
new file mode 100644
index 0000000..eca63ee
--- /dev/null
+++ b/examples/static/priv/video.html
@@ -0,0 +1,11 @@
+<!DOCTYPE html>
+<html>
+<body>
+ <h1>HTML5 Video Example</h1>
+ <video controls>
+ <source src="small.ogv" type="video/ogg"/>
+ <source src="small.mp4" type="video/mp4"/>
+ </video>
+ <p>Videos taken from <a href="http://techslides.com/sample-webm-ogg-and-mp4-video-files-for-html5/">TechSlides</a></p>
+</body>
+</html>
diff --git a/examples/static/start.sh b/examples/static/start.sh
index ab15739..bc67846 100755
--- a/examples/static/start.sh
+++ b/examples/static/start.sh
@@ -1,3 +1,4 @@
#!/bin/sh
erl -pa ebin deps/*/ebin -s static \
- -eval "io:format(\"Point your browser at http://localhost:8080/test.txt~n\")."
+ -eval "io:format(\"Point your browser at http://localhost:8080/test.txt~n\")." \
+ -eval "io:format(\"Point your browser at http://localhost:8080/video.html~n\")."