Fixed oversight from removing the proxy stuff.
This commit is contained in:
parent
f45dc55d48
commit
ef05ad5b9c
3 changed files with 3 additions and 0 deletions
|
@ -17,6 +17,7 @@ final class AudioTag extends BBCodeTag {
|
||||||
//$url['host'] = mb_strtolower($url['host']);
|
//$url['host'] = mb_strtolower($url['host']);
|
||||||
|
|
||||||
//$mediaUrl = url_proxy_media($matches[1]);
|
//$mediaUrl = url_proxy_media($matches[1]);
|
||||||
|
$mediaUrl = $matches[1];
|
||||||
return "<audio controls src='{$mediaUrl}'></audio>";
|
return "<audio controls src='{$mediaUrl}'></audio>";
|
||||||
},
|
},
|
||||||
$text
|
$text
|
||||||
|
|
|
@ -7,6 +7,7 @@ final class ImageTag extends BBCodeTag {
|
||||||
public function parseText(string $text): string {
|
public function parseText(string $text): string {
|
||||||
return preg_replace_callback("/\[img\]((?:https?:\/\/).+?)\[\/img\]/", function ($matches) {
|
return preg_replace_callback("/\[img\]((?:https?:\/\/).+?)\[\/img\]/", function ($matches) {
|
||||||
//$mediaUrl = url_proxy_media($matches[1]);
|
//$mediaUrl = url_proxy_media($matches[1]);
|
||||||
|
$mediaUrl = $matches[1];
|
||||||
return sprintf('<img src="%s" alt="%s" style="max-width:100%%;max-height:900px;">', $mediaUrl, $matches[1]);
|
return sprintf('<img src="%s" alt="%s" style="max-width:100%%;max-height:900px;">', $mediaUrl, $matches[1]);
|
||||||
}, $text);
|
}, $text);
|
||||||
}
|
}
|
||||||
|
|
|
@ -44,6 +44,7 @@ final class VideoTag extends BBCodeTag {
|
||||||
}
|
}
|
||||||
|
|
||||||
//$mediaUrl = url_proxy_media($matches[1]);
|
//$mediaUrl = url_proxy_media($matches[1]);
|
||||||
|
$mediaUrl = $matches[1];
|
||||||
return sprintf('<video controls src="%s" style="max-width:100%%;max-height:100%%;"></video>', $mediaUrl);
|
return sprintf('<video controls src="%s" style="max-width:100%%;max-height:100%%;"></video>', $mediaUrl);
|
||||||
},
|
},
|
||||||
$text
|
$text
|
||||||
|
|
Loading…
Reference in a new issue