Code
Explorer
You are a developer and looking for Shopware projects?
Apply Now!
withoutAttributeSanitizer example
public
function
sanitizeAttribute
(
string
$element
, string
$attribute
, string
$value
, HtmlSanitizerConfig
$config
)
: ?string
{
return
'';
}
}
;
$config
=
$config
->
withAttributeSanitizer
(
$sanitizer
)
;
$this
->
assertContains
(
$sanitizer
,
$config
->
getAttributeSanitizers
(
)
)
;
$config
=
$config
->
withoutAttributeSanitizer
(
$sanitizer
)
;
$this
->
assertNotContains
(
$sanitizer
,
$config
->
getAttributeSanitizers
(
)
)
;
}
}