OutputFilter

OutputFilter is a class for processing an output string for "safe" display

since

1.0

package

Joomla Framework

Methods

ampReplace

Makes a string safe for XHTML output by escaping ampersands.

ampReplace( text) : 
static
since

1.0

Arguments

text

stringText to process

Response

stringProcessed string.

cleanText

Cleans text of all formatting and scripting code.

cleanText(string &text) : 
static
since

1.0

Arguments

text

string|nullText to clean

Response

stringCleaned text.

linkXhtmlSafe

Makes a string safe for XHTML output by escaping ampersands in links.

linkXhtmlSafe( input) : 
static
since

1.0

Arguments

input

stringString to process

Response

stringProcessed string

objectHtmlSafe

Makes an object safe to display in forms.

objectHtmlSafe( &mixed,  quoteStyle = ENT_QUOTES,  excludeKeys = '') : 
static

Object parameters that are non-string, array, object or start with underscore will be converted

since

1.0

Arguments

mixed

objectAn object to be parsed

quoteStyle

intThe optional quote style for the htmlspecialchars function

excludeKeys

mixedAn optional string single field name or array of field names not to be parsed (eg, for a textarea)

Response

void

setLanguage

Set a Language instance for use

setLanguage(\Joomla\Language\Language language) : 
static
since

2.0.0

Arguments

language

LanguageThe Language instance to use.

Response

void

stringJSSafe

Processes a string and escapes it for use in JavaScript

stringJSSafe( string) : 
static
since

3.0

Arguments

string

stringString to process

Response

stringProcessed text

stringUrlSafe

Generates a URL safe version of the specified string with language transliteration.

stringUrlSafe( string,  language = '') : 
static

This method processes a string and replaces all accented UTF-8 characters by unaccented ASCII-7 "equivalents"; whitespaces are replaced by hyphens and the string is lowercased.

since

1.0

Arguments

string

stringString to process

language

stringLanguage to transliterate to

Response

stringProcessed string

stringUrlUnicodeSlug

Generates a URL safe version of the specified string with unicode character replacement.

stringUrlUnicodeSlug( string) : 
static
since

1.0

Arguments

string

stringString to process

Response

stringProcessed string

stripIframes

Strips <iframe> tags from a string.

stripIframes( string) : 
static
since

1.0

Arguments

string

stringSting to be cleaned.

Response

stringCleaned string

stripImages

Strips <img> tags from a string.

stripImages( string) : 
static
since

1.0

Arguments

string

stringSting to be cleaned.

Response

stringCleaned string

Properties

language

Language instance for making a string URL safe

static
since

2.0.0

Type(s)

Language|null