mirror of
https://github.com/ezyang/htmlpurifier.git
synced 2024-12-23 08:51:53 +00:00
15 lines
363 B
PHP
15 lines
363 B
PHP
|
<?php
|
||
|
|
||
|
/**
|
||
|
* Writes default type for all objects. Currently only supports flash.
|
||
|
*/
|
||
|
class HTMLPurifier_AttrTransform_SafeObject extends HTMLPurifier_AttrTransform
|
||
|
{
|
||
|
var $name = "SafeObject";
|
||
|
|
||
|
function transform($attr, $config, $context) {
|
||
|
if (!isset($attr['type'])) $attr['type'] = 'application/x-shockwave-flash';
|
||
|
return $attr;
|
||
|
}
|
||
|
}
|