Class HTMLPurifier_AttrDef_URI_IPv4

InheritanceHTMLPurifier_AttrDef_URI_IPv4 » HTMLPurifier_AttrDef
SubclassesHTMLPurifier_AttrDef_URI_IPv6

Validates an IPv4 address

Public Properties

Hide inherited properties

PropertyTypeDescriptionDefined By
$minimized Tells us whether or not an HTML attribute is minimized. HTMLPurifier_AttrDef
$required Tells us whether or not an HTML attribute is required. HTMLPurifier_AttrDef

Protected Properties

Hide inherited properties

PropertyTypeDescriptionDefined By
$ip4 IPv4 regex, protected so that IPv6 can reuse it. HTMLPurifier_AttrDef_URI_IPv4

Public Methods

Hide inherited methods

MethodDescriptionDefined By
make() Factory method for creating this class from a string. HTMLPurifier_AttrDef
parseCDATA() Convenience method that parses a string as if it were CDATA. HTMLPurifier_AttrDef
validate() HTMLPurifier_AttrDef_URI_IPv4

Protected Methods

Hide inherited methods

MethodDescriptionDefined By
_loadRegex() Lazy load function to prevent regex from being stuffed in cache. HTMLPurifier_AttrDef_URI_IPv4
expandCSSEscape() Parses a possibly escaped CSS string and returns the "pure" version of it. HTMLPurifier_AttrDef
mungeRgb() Removes spaces from rgb(0, 0, 0) so that shorthand CSS properties work properly. THIS IS A HACK! HTMLPurifier_AttrDef

Property Details

$ip4 protected property
protected $ip4 null

Method Details

_loadRegex() protected method

Lazy load function to prevent regex from being stuffed in cache.

protected void _loadRegex ( )
validate() public method

public bool|string validate ( $aIP, $config, $context )
$aIP string
$config HTMLPurifier_Config
$context HTMLPurifier_Context