아이디/닉네임 필터링 방식을 더 일관성있게 고침

This commit is contained in:
Kijin Sung 2015-07-08 11:09:11 +09:00
parent 0cf5888332
commit 50f9250d78
2 changed files with 12 additions and 8 deletions

View file

@ -80,13 +80,12 @@ class memberAdminController extends member
}
// remove whitespace
$checkInfos = array('user_id', 'nick_name', 'email_address');
$replaceStr = array("\r\n", "\r", "\n", " ", "\t", "\xC2\xAD");
$checkInfos = array('user_id', 'user_name', 'nick_name', 'email_address');
foreach($checkInfos as $val)
{
if(isset($args->{$val}))
{
$args->{$val} = str_replace($replaceStr, '', $args->{$val});
$args->{$val} = preg_replace('/[\pZ\pC]+/u', '', $args->{$val});
}
}