Skip to content

Commit

Permalink
unacms#4761 Oembed.php shouldn't process links if Oembed provider is …
Browse files Browse the repository at this point in the history
…disabled
  • Loading branch information
Alex Trofimov committed Aug 7, 2024
1 parent e980127 commit 74b9bcc
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion oembed.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@
require_once('./inc/header.inc.php');
require_once(BX_DIRECTORY_PATH_INC . "design.inc.php");

if (getParam('sys_embed_default') != 'sys_oembed')
exit;

$aLinks = bx_get('l');

bx_import('BxDolEmbed');
Expand All @@ -18,4 +21,4 @@
echo '<meta name="viewport" content="width=device-width; initial-scale=1.0; maximum-scale=1.0; user-scalable=0;"" /><style>body, html {margin:0px} A{text-decoration:none; color:#222}</style><div style=" margin:0px auto; justify-content: center;" id="ifr">' . $oEmbed->getLinkHTML($aLinks) . '</div>';
else
echoJson($oEmbed->parseLinks($aLinks));
}
}

0 comments on commit 74b9bcc

Please sign in to comment.