Skip to content

파일 크기 제한, 문서 첨부 제한 설정 오류 수정#1953

Merged
1 commit merged into
xpressengine:developfrom
soochan-lee:patch-2
Sep 5, 2016
Merged

파일 크기 제한, 문서 첨부 제한 설정 오류 수정#1953
1 commit merged into
xpressengine:developfrom
soochan-lee:patch-2

Conversation

@soochan-lee

Copy link
Copy Markdown
Contributor

upload_max_filesize가 MB단위로 되어있지 않은 경우(ex. 2G) 발생하던 오류를 수정했습니다.

upload_max_filesize가 MB단위로 되어있지 않은 경우(ex. 2G) 발생하던 오류를 수정했습니다.
@YJSoft

YJSoft commented Aug 30, 2016

Copy link
Copy Markdown
Contributor

@lsc2687 FileHandler에 returnBytes 함수가 있습니다.

function returnBytes($val)
{
$unit = strtoupper(substr($val, -1));
$val = (float)$val;
switch ($unit)
{
case 'G': $val *= 1024;
case 'M': $val *= 1024;
case 'K': $val *= 1024;
}
return round($val);
}

@ghost ghost self-assigned this Aug 31, 2016
@ghost ghost added this to the 1.8.25 milestone Sep 2, 2016
@ghost ghost added the type/bug label Sep 2, 2016
@ghost ghost merged commit 9ea5fd1 into xpressengine:develop Sep 5, 2016
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants