mirror of
https://github.com/ezyang/htmlpurifier.git
synced 2024-12-22 16:31:53 +00:00
Allows commas in tel URI scheme validator (addresses #388)
This commit is contained in:
parent
ab21ea735a
commit
8429f7b507
@ -35,7 +35,7 @@ class HTMLPurifier_URIScheme_tel extends HTMLPurifier_URIScheme
|
|||||||
|
|
||||||
// Delete all non-numeric characters, non-x characters
|
// Delete all non-numeric characters, non-x characters
|
||||||
// from phone number, EXCEPT for a leading plus sign.
|
// from phone number, EXCEPT for a leading plus sign.
|
||||||
$uri->path = preg_replace('/(?!^\+)[^\dx]/', '',
|
$uri->path = preg_replace('/(?!^\+)[^\dx,]/', '',
|
||||||
// Normalize e(x)tension to lower-case
|
// Normalize e(x)tension to lower-case
|
||||||
str_replace('X', 'x', rawurldecode($uri->path)));
|
str_replace('X', 'x', rawurldecode($uri->path)));
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user