Add isempty check for POST variable for multi file upload via URL

This commit is contained in:
Benjamin Southall 2017-03-23 01:10:53 +09:00
parent 4800138b29
commit 9b9b0f0a7e

View File

@ -589,7 +589,9 @@ if (isset($_POST['delete'])) {
for( $counter = 1; $counter <= $config['max_images']; $counter++ ) { for( $counter = 1; $counter <= $config['max_images']; $counter++ ) {
$varname = "file_url". $counter; $varname = "file_url". $counter;
upload_by_url($config,$post,$_POST[$varname]); if (isset($_POST[$varname]) && !empty($_POST[$varname])){
upload_by_url($config,$post,$_POST[$varname]);
}
} }
} }