Class XSSFilter

Description

Configurable XSSFilter for use by developers.

Located in /XSSFilter.class.php (line 134)


	
			
Variable Summary
Method Summary
 XSSFilter __construct ([bool $remove_html = False], [bool $remove_javascript = False], [bool $escape_html = True], [bool $urlencode_html = False], [bool $extended_return = False])
 void filter (string $data)
 array filter_array (array $data)
 string filter_string (string $data)
Variables
bool $escape_html (line 150)

Class variable noting if html should be escaped.

  • access: public
bool $extended_return (line 163)

Class variable noting if the return value should be a structure which includes the scrubbed data and a boolean noting if the data was modified or not.

A return of False means no changes, True means changes.

  • access: public
bool $remove_html (line 140)

Class variable noting if html should be removed.

  • access: public
bool $remove_javascript (line 145)

Class variable noting if javascript should be removed.

  • access: public
bool $urlencode_html (line 155)

Class variable noting if html should be urlencoded.

  • access: public
Methods
Constructor __construct (line 174)

A filter object that attempts to strip out evil data.

XSSFilter __construct ([bool $remove_html = False], [bool $remove_javascript = False], [bool $escape_html = True], [bool $urlencode_html = False], [bool $extended_return = False])
  • bool $remove_html: remove_html if html should be removed.
  • bool $remove_javascript: remove_javascript if javascript should be removed.
  • bool $escape_html: escape_html if html should be escaped.
  • bool $urlencode_html: urlencode_html if html should be urlencoded.
  • bool $extended_return: extended_return if an extended object should be used.
filter (line 187)

Forward method for filtering input.

void filter (string $data)
  • string $data: data the data to filter.
filter_array (line 228)

Filters a single level array.

  • return: a safer array.
array filter_array (array $data)
  • array $data: data the data filled array to filter.
filter_string (line 199)

Filters a single input item

  • return: a safer string.
string filter_string (string $data)
  • string $data: data the data to filter.

Documentation generated on Tue, 12 Oct 2010 16:47:12 -0400 by phpDocumentor 1.4.3