ILIAS
release_5-3 Revision v5.3.23-19-g915713cf615
◀ ilDoc Overview
tel.php
Go to the documentation of this file.
1
<?php
2
12
class
HTMLPurifier_URIScheme_tel
extends
HTMLPurifier_URIScheme
13
{
17
public
$browsable
=
false
;
18
22
public
$may_omit_host
=
true
;
23
30
public
function
doValidate
(&$uri,
$config
, $context)
31
{
32
$uri->userinfo = null;
33
$uri->host = null;
34
$uri->port = null;
35
36
// Delete all non-numeric characters, non-x characters
37
// from phone number, EXCEPT for a leading plus sign.
38
$uri->path = preg_replace(
'/(?!^\+)[^\dx]/'
,
''
,
39
// Normalize e(x)tension to lower-case
40
str_replace(
'X'
,
'x'
, $uri->path));
41
42
return
true
;
43
}
44
}
45
46
// vim: et sw=4 sts=4
$config
$config
Definition:
flush-definition-cache.php:23
HTMLPurifier_URIScheme_tel\$may_omit_host
$may_omit_host
bool
Definition:
tel.php:22
HTMLPurifier_URIScheme_tel
Validates tel (for phone numbers).
Definition:
tel.php:12
HTMLPurifier_URIScheme_tel\doValidate
doValidate(&$uri, $config, $context)
Definition:
tel.php:30
HTMLPurifier_URIScheme_tel\$browsable
$browsable
bool
Definition:
tel.php:17
HTMLPurifier_URIScheme
Validator for the components of a URI for a specific scheme.
Definition:
URIScheme.php:6
libs
composer
vendor
ezyang
htmlpurifier
library
HTMLPurifier
URIScheme
tel.php
Generated on Tue Jan 28 2025 19:01:04 for ILIAS by
1.8.13 (using
Doxyfile
)