Jump to content

jbriggs71

Members
  • Posts

    2
  • Joined

  • Last visited

jbriggs71's Achievements

Newbie

Newbie (1/7)

0

Reputation

  1. Thanks for the help. There are two things I found that could be done to take care of this message. The first was from your suggestions. I changed the code from $extention = end(explode(".", $_FILES["file"]["name"])); To this. $filename = $_FILES["file"]["name"];$test1 = explode(".", $filename);$extention = end($test1); The second thing I found to handle this problem war error reporting. Though not the option I took it works to prevent the user from seeing the error. ini_set('display_errors', '0');error_reporting(E_ALL | E_STRICT); The error is still being logged, but the user does not see it. Not sure why PHP would allow the error to be "covered up" if they do not want refrences passed.
  2. I am working through the php tutorials and have been doing well until I reached the file upload example found at http://www.w3schools.com/php/php_file_upload.asp. When uploading a file I get the message Strict Standards: Only variables should be passed by reference in C:\websites\upload_file_restrict.php on line 3The line referenced is $extention = end(explode(".", $_FILES["file"]["name"])); I have done some research on it, but I just have not been able to find an explanation that I understand as to why it is happening and how to correct it.
×
×
  • Create New...