URLからvimeoビデオIDを取得するのに最適な正規表現を見つけようとしています。
URL の例:
https://vimeo.com/11111111
http://vimeo.com/11111111
https://www.vimeo.com/11111111
http://www.vimeo.com/11111111
https://vimeo.com/channels/11111111
http://vimeo.com/channels/11111111
https://vimeo.com/groups/name/videos/11111111
http://vimeo.com/groups/name/videos/11111111
https://vimeo.com/album/2222222/video/11111111
http://vimeo.com/album/2222222/video/11111111
https://vimeo.com/11111111?param=test
http://vimeo.com/11111111?param=test
動作しない私の現在の正規表現:
/http:\/\/(www\.)?vimeo.com\/(\d+)($|\/)/
プレイグラウンドとテストはこちら: http://jsbin.com/asuqic/1/edit?javascript,live