#772 favicon mime type 을 x-icon 지원 하도록 수정, favicon 크기 검사 안하도록 수정

This commit is contained in:
akasima 2014-06-04 23:13:38 +09:00
parent c4881ba915
commit 3c191b8373

View file

@ -335,14 +335,10 @@ class installAdminController extends install
list($width, $height, $type_no, $attrs) = @getimagesize($target_file); list($width, $height, $type_no, $attrs) = @getimagesize($target_file);
if($iconname == 'favicon.ico') if($iconname == 'favicon.ico')
{ {
if(!preg_match('/^.*\.icon$/i',$type)) { if(!preg_match('/^.*(x-icon|\.icon)$/i',$type)) {
Context::set('msg', '*.ico '.Context::getLang('msg_possible_only_file')); Context::set('msg', '*.ico '.Context::getLang('msg_possible_only_file'));
return; return;
} }
if($width && $height && ($width != '16' || $height != '16')) {
Context::set('msg', Context::getLang('msg_invalid_format').' (size : 16x16)');
return;
}
} }
else if($iconname == 'mobicon.png') else if($iconname == 'mobicon.png')
{ {