mirror of
https://github.com/HaschekSolutions/pictshare.git
synced 2025-11-19 06:28:01 +00:00
added "-" to the allowed characters in sanatize method
This commit is contained in:
@@ -2,9 +2,18 @@
|
|||||||
|
|
||||||
class HTML {
|
class HTML {
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Characters that will pass:
|
||||||
|
* a-z
|
||||||
|
* A-Z
|
||||||
|
* 0-9
|
||||||
|
* .
|
||||||
|
* _
|
||||||
|
* -
|
||||||
|
*/
|
||||||
function sanatizeString($string)
|
function sanatizeString($string)
|
||||||
{
|
{
|
||||||
return preg_replace("/[^a-zA-Z0-9._]+/", "", $string);
|
return preg_replace("/[^a-zA-Z0-9._\-]+/", "", $string);
|
||||||
}
|
}
|
||||||
|
|
||||||
function renderSize($byte)
|
function renderSize($byte)
|
||||||
|
|||||||
Reference in New Issue
Block a user