17 parent::__construct(
true);
32 if (strpos($uri_string,
'url(') !== 0) {
35 $uri_string = substr($uri_string, 4);
36 if (strlen($uri_string) == 0) {
39 $new_length = strlen($uri_string) - 1;
40 if ($uri_string[$new_length] !=
')') {
43 $uri = trim(substr($uri_string, 0, $new_length));
45 if (!empty($uri) && ($uri[0] ==
"'" || $uri[0] ==
'"')) {
47 $new_length = strlen($uri) - 1;
48 if ($uri[$new_length] !== $quote) {
51 $uri = substr($uri, 1, $new_length - 1);
73 return "url(\"$result\")";
validate($uri_string, $config, $context)
parseCDATA($string)
Convenience method that parses a string as if it were CDATA.
expandCSSEscape($string)
Parses a possibly escaped CSS string and returns the "pure" version of it.
Validates a URI in CSS syntax, which uses url('http://example.com')
Create styles array
The data for the language used.
Validates a URI as defined by RFC 3986.