Browse Source

Changed extension to allow multiple . inside (like .tar.gz)

development
Teknikode 4 years ago
parent
commit
7c1e31922a
1 changed files with 3 additions and 2 deletions
  1. 3
    2
      includes/common.php

+ 3
- 2
includes/common.php View File

@@ -174,7 +174,8 @@ function upload($files, $CONF, $db)
if (!empty($files)) {
$filesize = filesize($files['file']['tmp_name']);
$file_type = mime_content_type($files['file']['tmp_name']);
$ext = pathinfo($files['file']['name'], PATHINFO_EXTENSION);
//$ext = pathinfo($files['file']['name'], PATHINFO_EXTENSION);
$ext = substr($files['file']['name'], strrpos($files['file']['name'], '.')+1);
if ($logged_in == 1)
{
$user_id = $user->id;
@@ -657,4 +658,4 @@ function multi_array_search($array, $search)
// Return the result array
return $result;
}
?>
?>

Loading…
Cancel
Save