Small change to bring this check in line with the other image checks (remote avatars and img tags)

git-svn-id: file:///svn/phpbb/branches/phpBB-2_0_0@5962 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
Graham Eames 2006-05-23 21:09:27 +00:00
parent 1cee6fcf41
commit 0821474a5c

View file

@ -122,7 +122,7 @@ function user_avatar_upload($mode, $avatar_mode, &$current_avatar, &$current_typ
$width = $height = 0; $width = $height = 0;
$type = ''; $type = '';
if ( $avatar_mode == 'remote' && preg_match('/^(http:\/\/)?([\w\-\.]+)\:?([0-9]*)\/(.*)$/', $avatar_filename, $url_ary) ) if ( $avatar_mode == 'remote' && preg_match('/^(http:\/\/)?([\w\-\.]+)\:?([0-9]*)\/([^ \?&=\#\"\n\r\t<]*?(\.(jpg|jpeg|gif|png)))$/', $avatar_filename, $url_ary) )
{ {
if ( empty($url_ary[4]) ) if ( empty($url_ary[4]) )
{ {