From 3ef0c43348c8f735bab740e4a9b7bf8df26fbb00 Mon Sep 17 00:00:00 2001 From: Christian Schneider Date: Wed, 22 Apr 2009 12:49:48 +0000 Subject: Get rid of ereg/split, replaced by preg equivalents --- it_user.class | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'it_user.class') diff --git a/it_user.class b/it_user.class index 85c44bd..328819b 100644 --- a/it_user.class +++ b/it_user.class @@ -385,7 +385,7 @@ function is_valid_username($name) { if ((strlen($name) >= 2) && (strlen($name) <= 32)) { - if (!ereg('["\'\\&\$+]', $name)) + if (!preg_match('/["\'\\\\&$+]/', $name)) return true; } return false; @@ -399,7 +399,7 @@ function is_valid_password($word) { if ((strlen($word) >= 2) && (strlen($word) <= 32)) { - if (!ereg('["\'\\&\$+]', $word)) + if (!preg_match('/["\'\\\\&$+]/', $word)) return true; } return false; @@ -492,7 +492,7 @@ function check_url($withsession = false) if (!empty($_SERVER['QUERY_STRING'])) { - $url = ereg_replace("&?$this->urlauthenticationcode=[a-zA-Z0-9]*", '', $_SERVER['REQUEST_URI']); + $url = preg_replace("/&?$this->urlauthenticationcode=[a-zA-Z0-9]*/", '', $_SERVER['REQUEST_URI']); $result = $this->check_signature($url, $GLOBALS[$this->urlauthenticationcode], $withsession); } -- cgit v1.2.3