1
0
mirror of https://github.com/ezyang/htmlpurifier.git synced 2025-08-05 21:57:26 +02:00

Refactor HTML.Noopener to HTML.TargetNoopener so that it behaves like HTML.TargetNoreferrer and is active by default if a target is set

This commit is contained in:
Bastian Hofmann
2017-01-13 17:21:24 +01:00
committed by Edward Z. Yang
parent c82051c3e1
commit 8e4cacf0a7
17 changed files with 154 additions and 129 deletions

View File

@@ -189,7 +189,7 @@ class HTMLPurifier_Strategy_ValidateAttributesTest extends
{
$this->config->set('Attr.AllowedFrameTargets', '_top');
$this->config->set('HTML.Doctype', 'XHTML 1.0 Transitional');
$this->assertResult('<a href="foo" target="_top" rel="noreferrer" />');
$this->assertResult('<a href="foo" target="_top" rel="noreferrer noopener" />');
}
public function testRemoveTargetWhenNotSupported()