18 $this->regexp = $config->get(
'URI.SafeIframeRegexp');
21 public function filter(&$uri, $config, $context) {
23 if (!$config->get(
'HTML.SafeIframe'))
return true;
25 if (!$context->get(
'EmbeddedURI',
true))
return true;
26 $token = $context->get(
'CurrentToken',
true);
27 if (!($token && $token->name ==
'iframe'))
return true;
29 if ($this->regexp === null)
return false;
31 return preg_match($this->regexp, $uri->toString());