tomayac/Media-Fragments-URI — pull request #2 by yunjiali (2014-08-25 15:30:08+00:00)
Title: Media Fragment URI Loose

Hi Tom,

Here are the "new" features I have added into the Loose parser:

1. uri should use protocol http or https (If we don't consider rtsp protocol)
2. use better uri parsing regex
3. consider the media fragments implemented by video sharing platforms. The following syntax are added:

pass http://www.youtube.com/watch?v=Wm15rvkifPc#t=120
pass http://www.youtube.com/watch?v=Wm15rvkifPc?pass http://www.youtube.com/watch?v=Wm15rvkifPc#t=120t=120
pass http://www.youtube.com/watch?v=Wm15rvkifPc&t=1h9m20s
pass http://www.youtube.com/watch?v=Wm15rvkifPc#t=1h9m20s
fail (minutes bigger than 59) http://www.youtube.com/watch?v=Wm15rvkifPc#t=1h96m20s
fail (seconds bigger than 59) http://www.youtube.com/watch?v=Wm15rvkifPc#t=1h6m80s

pass http://www.dailymotion.com/video/xjwusq&start=120
pass http://www.dailymotion.com/video/xjwusq?start=120
pass http://vimeo.com/812027#t=214

pass http://www.viddler.com/v/bb2a72e9?offset=12.083&secret=32758627
pass http://www.tudou.com/listplay/H9hyQbAj4NM/2tzZHTtq4GA.html?lvt=30
pass http://v.youku.com/v_show/id_XNjE2OTQ0MTI4.html?ev=5&firsttime=147
pass http://www.56.com/u92/v_OTgwMTk4NDk.html#st=737

4. seconds could be bigger than 60 as long as minutes and hours are empty
5. The support to use the library as a nodejs module

Please feel free to contact me if there is any problem. Many thanks.

Regards
Yunjia Li