Hi I am using Amazon PHP SDK to upload to s3. I am using fineuploader jQuery plugin on front end. Recently my hosting PHP version was upgraded to PHP5.4.34 and not the upload system is broken and when I look at the logs I see this error.
<br />
<b>Fatal error</b>: Uncaught exception 'LogicException' with message 'Illegal value passed (no array or string given)' in /home/on2dvd/public_html/fineuploader/aws/aws-autoloader.php:1270
Stack trace:
#0 /home/on2dvd/public_html/fineuploader/aws/aws-autoloader.php(1270): spl_autoload_register(NULL, true)
#1 /home/on2dvd/public_html/fineuploader/s3/s3handler.php(27): require('/home/on2dvd/pu...')
#2 {main}
thrown in <b>/home/on2dvd/public_html/fineuploader/aws/aws-autoloader.php</b> on line <b>1270</b><br />
I searched alot but could not find any solution for this. The error is in the aws-autoloader.php line 1270 and on this line the code is below. $mapping is an array containing the keys and class names. It was working fine in PHP 5.3 but not working any more after the upgrade.
spl_autoload_register(function ($class) use ($mapping) {
if (isset($mapping[$class])) {
require $mapping[$class];
}
}, true);