diff options
author | Klaus Weidenbach <Klaus.Weidenbach@gmx.net> | 2017-03-18 17:50:05 +0100 |
---|---|---|
committer | Klaus Weidenbach <Klaus.Weidenbach@gmx.net> | 2017-03-26 00:41:27 +0100 |
commit | f718e2b0db0fe3477212a8dd6c3ec067f4432862 (patch) | |
tree | 8dfbd3b3d4bdcd967b50f1ee4655440bcdef5bb8 /library/HTMLPurifier/HTMLModule/Text.php | |
parent | 2115eb26a7fd2ca937286bd4e98ab74c7d6e9525 (diff) | |
download | volse-hubzilla-f718e2b0db0fe3477212a8dd6c3ec067f4432862.tar.gz volse-hubzilla-f718e2b0db0fe3477212a8dd6c3ec067f4432862.tar.bz2 volse-hubzilla-f718e2b0db0fe3477212a8dd6c3ec067f4432862.zip |
:arrow_up: Update HTML Purifier library.
Updated HTML Purifier from 4.6.0 to 4.9.2 with better PHP7 compatibility.
Used composer to manage this library.
Diffstat (limited to 'library/HTMLPurifier/HTMLModule/Text.php')
-rw-r--r-- | library/HTMLPurifier/HTMLModule/Text.php | 87 |
1 files changed, 0 insertions, 87 deletions
diff --git a/library/HTMLPurifier/HTMLModule/Text.php b/library/HTMLPurifier/HTMLModule/Text.php deleted file mode 100644 index 7a65e0048..000000000 --- a/library/HTMLPurifier/HTMLModule/Text.php +++ /dev/null @@ -1,87 +0,0 @@ -<?php - -/** - * XHTML 1.1 Text Module, defines basic text containers. Core Module. - * @note In the normative XML Schema specification, this module - * is further abstracted into the following modules: - * - Block Phrasal (address, blockquote, pre, h1, h2, h3, h4, h5, h6) - * - Block Structural (div, p) - * - Inline Phrasal (abbr, acronym, cite, code, dfn, em, kbd, q, samp, strong, var) - * - Inline Structural (br, span) - * This module, functionally, does not distinguish between these - * sub-modules, but the code is internally structured to reflect - * these distinctions. - */ -class HTMLPurifier_HTMLModule_Text extends HTMLPurifier_HTMLModule -{ - /** - * @type string - */ - public $name = 'Text'; - - /** - * @type array - */ - public $content_sets = array( - 'Flow' => 'Heading | Block | Inline' - ); - - /** - * @param HTMLPurifier_Config $config - */ - public function setup($config) - { - // Inline Phrasal ------------------------------------------------- - $this->addElement('abbr', 'Inline', 'Inline', 'Common'); - $this->addElement('acronym', 'Inline', 'Inline', 'Common'); - $this->addElement('cite', 'Inline', 'Inline', 'Common'); - $this->addElement('dfn', 'Inline', 'Inline', 'Common'); - $this->addElement('kbd', 'Inline', 'Inline', 'Common'); - $this->addElement('q', 'Inline', 'Inline', 'Common', array('cite' => 'URI')); - $this->addElement('samp', 'Inline', 'Inline', 'Common'); - $this->addElement('var', 'Inline', 'Inline', 'Common'); - - $em = $this->addElement('em', 'Inline', 'Inline', 'Common'); - $em->formatting = true; - - $strong = $this->addElement('strong', 'Inline', 'Inline', 'Common'); - $strong->formatting = true; - - $code = $this->addElement('code', 'Inline', 'Inline', 'Common'); - $code->formatting = true; - - // Inline Structural ---------------------------------------------- - $this->addElement('span', 'Inline', 'Inline', 'Common'); - $this->addElement('br', 'Inline', 'Empty', 'Core'); - - // Block Phrasal -------------------------------------------------- - $this->addElement('address', 'Block', 'Inline', 'Common'); - $this->addElement('blockquote', 'Block', 'Optional: Heading | Block | List', 'Common', array('cite' => 'URI')); - $pre = $this->addElement('pre', 'Block', 'Inline', 'Common'); - $pre->excludes = $this->makeLookup( - 'img', - 'big', - 'small', - 'object', - 'applet', - 'font', - 'basefont' - ); - $this->addElement('h1', 'Heading', 'Inline', 'Common'); - $this->addElement('h2', 'Heading', 'Inline', 'Common'); - $this->addElement('h3', 'Heading', 'Inline', 'Common'); - $this->addElement('h4', 'Heading', 'Inline', 'Common'); - $this->addElement('h5', 'Heading', 'Inline', 'Common'); - $this->addElement('h6', 'Heading', 'Inline', 'Common'); - - // Block Structural ----------------------------------------------- - $p = $this->addElement('p', 'Block', 'Inline', 'Common'); - $p->autoclose = array_flip( - array("address", "blockquote", "center", "dir", "div", "dl", "fieldset", "ol", "p", "ul") - ); - - $this->addElement('div', 'Block', 'Flow', 'Common'); - } -} - -// vim: et sw=4 sts=4 |