mirror of
https://github.com/friendica/friendica
synced 2025-04-19 06:30:10 +00:00
Move [embed] bbtag from oembed plugin to core
This commit is contained in:
parent
d8877b88d6
commit
23d1b994cc
3 changed files with 52 additions and 45 deletions
|
@ -1,5 +1,5 @@
|
|||
<?php
|
||||
|
||||
require_once("include/oembed.php");
|
||||
// BBcode 2 HTML was written by WAY2WEB.net
|
||||
// extended to work with Mistpark/Friendika - Mike Macgirvin
|
||||
|
||||
|
@ -93,6 +93,9 @@ function bbcode($Text) {
|
|||
$Text = preg_replace("/\[youtube\]http:\/\/www.youtube.com\/watch\?v\=(.+?)\[\/youtube\]/",'[youtube]$1[/youtube]',$Text);
|
||||
$Text = preg_replace("/\[youtube\](.+?)\[\/youtube\]/", '<object width="425" height="350" type="application/x-shockwave-flash" data="http://www.youtube.com/v/$1" ><param name="movie" value="http://www.youtube.com/v/$1"></param><!--[if IE]><embed src="http://www.youtube.com/v/$1" type="application/x-shockwave-flash" width="425" height="350" /><![endif]--></object>', $Text);
|
||||
|
||||
// oembed tag
|
||||
$Text = oembed_bbcode($Text);
|
||||
|
||||
call_hooks('bbcode',$Text);
|
||||
|
||||
return $Text;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue