aboutsummaryrefslogtreecommitdiffstats
path: root/include/items.php
diff options
context:
space:
mode:
Diffstat (limited to 'include/items.php')
-rw-r--r--include/items.php10
1 files changed, 10 insertions, 0 deletions
diff --git a/include/items.php b/include/items.php
index 8c2c78696..3170b9384 100644
--- a/include/items.php
+++ b/include/items.php
@@ -354,6 +354,9 @@ function get_atom_elements($feed,$item) {
$res['body'] = preg_replace('#<object[^>]+>.+?' . 'http://www.youtube.com/((?:v|cp)/[A-Za-z0-9\-_=]+).+?</object>#s',
'[youtube]$1[/youtube]', $res['body']);
+ $res['body'] = preg_replace('#<iframe[^>].+?' . 'http://www.youtube.com/embed/[A-Za-z0-9\-_=]+).+?</iframe>#s',
+ '[youtube]$1[/youtube]', $res['body']);
+
$res['body'] = oembed_html2bbcode($res['body']);
$config = HTMLPurifier_Config::createDefault();
@@ -521,6 +524,10 @@ function get_atom_elements($feed,$item) {
$body = preg_replace('#<object[^>]+>.+?' . 'http://www.youtube.com/((?:v|cp)/[A-Za-z0-9\-_=]+).+?</object>#s',
'[youtube]$1[/youtube]', $body);
+ $res['body'] = preg_replace('#<iframe[^>].+?' . 'http://www.youtube.com/embed/[A-Za-z0-9\-_=]+).+?</iframe>#s',
+ '[youtube]$1[/youtube]', $res['body']);
+
+
$config = HTMLPurifier_Config::createDefault();
$config->set('Cache.DefinitionImpl', null);
@@ -560,6 +567,9 @@ function get_atom_elements($feed,$item) {
$body = preg_replace('#<object[^>]+>.+?' . 'http://www.youtube.com/((?:v|cp)/[A-Za-z0-9\-_=]+).+?</object>#s',
'[youtube]$1[/youtube]', $body);
+ $res['body'] = preg_replace('#<iframe[^>].+?' . 'http://www.youtube.com/embed/[A-Za-z0-9\-_=]+).+?</iframe>#s',
+ '[youtube]$1[/youtube]', $res['body']);
+
$config = HTMLPurifier_Config::createDefault();
$config->set('Cache.DefinitionImpl', null);