aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorz0rglub <z0rglub@piwigo.org>2004-10-07 21:41:09 +0000
committerz0rglub <z0rglub@piwigo.org>2004-10-07 21:41:09 +0000
commitdeb89a13d8450fe0e6d4db2f49e3861a0e130354 (patch)
treea4513ca433e2d7ec09422260a7961bc4b59d4c76
parent44370399ee5677d1c3578a9c54e8bc1a1140f945 (diff)
- bug 53 : parse error on line 40
- bug 54 : no picture extension allowed for picture upload - bug 56 : wrong error message for exceeding filesize picture git-svn-id: http://piwigo.org/svn/branches/release-1_3@556 68402e56-0260-453c-a942-63ccdbb3a9ee
-rw-r--r--upload.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/upload.php b/upload.php
index 986b388cc..3d3261717 100644
--- a/upload.php
+++ b/upload.php
@@ -36,7 +36,7 @@ function validate_upload( $temp_name, $my_max_file_size,
$result['error'] = array();
//echo $_FILES['picture']['name']."<br />".$temp_name;
$extension = get_extension( $_FILES['picture']['name'] );
- if ( in_array( $extension, $conf['picture_ext'] )
+ if ( !in_array( $extension, $conf['picture_ext'] ) )
{
array_push( $result['error'], $lang['upload_advise_filetype'] );
return $result;
@@ -49,7 +49,7 @@ function validate_upload( $temp_name, $my_max_file_size,
else if ( $_FILES['picture']['size'] > $my_max_file_size * 1024 )
{
array_push( $result['error'],
- $lang['upload_advise_width'].$my_max_file_size.' KB' );
+ $lang['upload_advise_filesize'].$my_max_file_size.' KB' );
}
else
{