|
@@ 10837-10841 (lines=5) @@
|
| 10834 |
|
public static function verify_document_size($s) |
| 10835 |
|
{ |
| 10836 |
|
$post_max = ini_get('post_max_size'); |
| 10837 |
|
if (substr($post_max, -1, 1) == 'M') { |
| 10838 |
|
$post_max = intval(substr($post_max, 0, -1)) * 1024 * 1024; |
| 10839 |
|
} elseif (substr($post_max, -1, 1) == 'G') { |
| 10840 |
|
$post_max = intval(substr($post_max, 0, -1)) * 1024 * 1024 * 1024; |
| 10841 |
|
} |
| 10842 |
|
$upl_max = ini_get('upload_max_filesize'); |
| 10843 |
|
if (substr($upl_max, -1, 1) == 'M') { |
| 10844 |
|
$upl_max = intval(substr($upl_max, 0, -1)) * 1024 * 1024; |
|
@@ 10843-10847 (lines=5) @@
|
| 10840 |
|
$post_max = intval(substr($post_max, 0, -1)) * 1024 * 1024 * 1024; |
| 10841 |
|
} |
| 10842 |
|
$upl_max = ini_get('upload_max_filesize'); |
| 10843 |
|
if (substr($upl_max, -1, 1) == 'M') { |
| 10844 |
|
$upl_max = intval(substr($upl_max, 0, -1)) * 1024 * 1024; |
| 10845 |
|
} elseif (substr($upl_max, -1, 1) == 'G') { |
| 10846 |
|
$upl_max = intval(substr($upl_max, 0, -1)) * 1024 * 1024 * 1024; |
| 10847 |
|
} |
| 10848 |
|
$documents_total_space = DocumentManager::documents_total_space(); |
| 10849 |
|
$course_max_space = DocumentManager::get_course_quota(); |
| 10850 |
|
$total_size = filesize($s) + $documents_total_space; |