PHP Класс ElggAutoP, Elgg

In DIV elements, Ps are only added when there would be at least two of them.
Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
$encoding

Защищенные свойства (Protected)

Свойство Тип Описание
$_alterList array Add Ps inside these elements
$_blocks
$_descendList array Descend into these elements to add Ps
$_doc DOMDocument
$_inlines array
$_unique string
$_xpath DOMXPath

Открытые методы

Метод Описание
__construct ( ) Constructor
process ( string $html ) : string | false Create wrapper P and BR elements in HTML depending on newlines. Useful when users use newlines to signal line and paragraph breaks. In all cases output should be well-formed markup.

Защищенные методы

Метод Описание
addParagraphs ( DOMElement $el ) : void Add P and BR elements as necessary

Описание методов

__construct() публичный Метод

Constructor
public __construct ( )

addParagraphs() защищенный Метод

Add P and BR elements as necessary
protected addParagraphs ( DOMElement $el ) : void
$el DOMElement DOM element
Результат void

process() публичный Метод

In DIV, LI, TD, and TH elements, Ps are only added when their would be at least two of them.
public process ( string $html ) : string | false
$html string snippet
Результат string | false output or false if parse error occurred

Описание свойств

$_alterList защищенное свойство

Add Ps inside these elements
protected array $_alterList
Результат array

$_blocks защищенное свойство

protected $_blocks

$_descendList защищенное свойство

Descend into these elements to add Ps
protected array $_descendList
Результат array

$_doc защищенное свойство

protected DOMDocument $_doc
Результат DOMDocument

$_inlines защищенное свойство

protected array $_inlines
Результат array

$_unique защищенное свойство

protected string $_unique
Результат string

$_xpath защищенное свойство

protected DOMXPath $_xpath
Результат DOMXPath

$encoding публичное свойство

public $encoding