shortcode->getRawHandlers()->add('googleslides', function(ShortcodeInterface $sc) { // Get shortcode content and parameters $str = $sc->getContent(); $googleslidesurl= $sc->getParameter('url', $sc->getBbCode()); if ($googleslidesurl) { $output = '
'; return $output; } else { if ($str) { return '
'; } } }); } }