Target.php 503 B

1234567891011121314151617181920212223
  1. <?php
  2. /**
  3. * XHTML 1.1 Target Module, defines target attribute in link elements.
  4. */
  5. class HTMLPurifier_HTMLModule_Target extends HTMLPurifier_HTMLModule
  6. {
  7. public $name = 'Target';
  8. public function setup($config) {
  9. $elements = array('a');
  10. foreach ($elements as $name) {
  11. $e = $this->addBlankElement($name);
  12. $e->attr = array(
  13. 'target' => new HTMLPurifier_AttrDef_HTML_FrameTarget()
  14. );
  15. }
  16. }
  17. }
  18. // vim: et sw=4 sts=4