Skip to content

Commit

Permalink
Fix use of undefined constant
Browse files Browse the repository at this point in the history
In is_file_to_upload.php, change the array key's error and name from
constants to strings: 'error' and 'name'.
  • Loading branch information
dcslagel committed Aug 21, 2020
1 parent 9df2ab7 commit 9b0f9c4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions prj/src/is_file_to_upload.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ function is_file_to_upload()
function status_msg_for_upload()
{
$message_text = "&nbsp";
$upload_error = $_FILES['fileToUpload'][error];
$upload_name = $_FILES['fileToUpload'][name];
$upload_error = $_FILES['fileToUpload']['error'];
$upload_name = $_FILES['fileToUpload']['name'];
$data_link_name = ($_SESSION['fileToUpload']['new_name']);

if (empty($upload_error) && !empty($upload_name)) {
Expand Down

0 comments on commit 9b0f9c4

Please sign in to comment.