Commit 8c356af9 authored by Nigel McNie's avatar Nigel McNie
Browse files

Loosen the rule matching youtube videos slightly so more stuff will work

parent cc21b7cd
......@@ -114,8 +114,8 @@ class PluginBlocktypeExternalvideo extends SystemBlocktype {
private static function make_video_url($url) {
static $embedsources = array(
array(
'match' => '#.*youtube\.com.*v=([a-zA-Z0-9-]+).*#',
'url' => 'http://www.youtube.com/v/$1'
'match' => '#.*youtube\.com.*v(=|\/)([a-zA-Z0-9-]+).*#',
'url' => 'http://www.youtube.com/v/$2'
),
array(
'match' => '#.*video.google.com.*docid=(\-?[0-9]+).*#',
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment