PHP Класс Prado\Web\UI\WebControls\TLiteral

TLiteral displays a static text on the Web page. TLiteral is similar to the TLabel control, except that the TLiteral control does not have style properties (e.g. BackColor, Font, etc.) You can programmatically control the text displayed in the control by setting the {@link setText Text} property. The text displayed may be HTML-encoded if the {@link setEncode Encode} property is set true (defaults to false). TLiteral will render the contents enclosed within its component tag if {@link setText Text} is empty. Note, if {@link setEncode Encode} is false, make sure {@link setText Text} does not contain unwanted characters that may bring security vulnerabilities.
С версии: 3.0
Автор: Qiang Xue ([email protected])
Наследование: extends Prado\Web\UI\TControl, implements Prado\IDataRenderer
Показать файл Открыть проект

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

Метод Описание
getData ( ) : string Returns the static text of the TLiteral.
getEncode ( ) : boolean
getText ( ) : string
render ( $writer ) Renders the literal control.
setData ( $value ) Sets the static text of the TLiteral.
setEncode ( $value )
setText ( $value ) Sets the static text of the TLiteral

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

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

This method is required by {@link \Prado\IDataRenderer}. It is the same as {@link getText()}.
См. также: getText
С версии: 3.1.0
public getData ( ) : string
Результат string the static text of the TLiteral

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

public getEncode ( ) : boolean
Результат boolean whether the rendered text should be HTML-encoded. Defaults to false.

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

public getText ( ) : string
Результат string the static text of the TLiteral

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

Renders the literal control.
public render ( $writer )

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

This method is required by {@link \Prado\IDataRenderer}. It is the same as {@link setText()}.
См. также: setText
С версии: 3.1.0
public setData ( $value )

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

public setEncode ( $value )

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

Sets the static text of the TLiteral
public setText ( $value )