diff --git a/extlib/Services/oEmbed.php b/extlib/Services/oEmbed.php
index 7d507b6f62..b05e3a1d14 100644
--- a/extlib/Services/oEmbed.php
+++ b/extlib/Services/oEmbed.php
@@ -303,7 +303,7 @@ class Services_oEmbed
// Find all tags that have a valid oembed type set. We then
// extract the href attribute for each type.
$regexp = '#]*)type="' .
- '(application/json|text/xml)\+oembed"([^>]*)>#i';
+ '(application/json|text/xml)\+oembed"([^>]*)>#im';
$m = $ret = array();
if (!preg_match_all($regexp, $body, $m)) {