jka Posted April 1, 2016 Share Posted April 1, 2016 I am trying to upload images under Products and its not doing it anything, when I Save. Nothing gets uploaded. I went into images under File Manager and tried from there. Its shows up under Files and when I try to edit it, an error pops with the message "image no longer exists". Any pointers? Is this a permission issue on any of the folders? Thanks. Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted April 1, 2016 Share Posted April 1, 2016 Permissions on my images folder is 755. Quote Link to comment Share on other sites More sharing options...
jka Posted April 1, 2016 Author Share Posted April 1, 2016 Now I am able to see the image name in the images box under products however when I click on it, it pops up a grey box. The same on the website under products. Is this a format of .jpg that the system doesnt like? Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted April 1, 2016 Share Posted April 1, 2016 Please give the full url of one of your images. Are you on 6.0.11 with Foundation? Quote Link to comment Share on other sites More sharing options...
jka Posted April 1, 2016 Author Share Posted April 1, 2016 We are on 5.2.16. There is no image on the url. Its blank with no image. Unable to upload images all types. I did change the "admin" folder name as well as rename admin.php, but the new value are in global settings file. Can this be the issue? I can revert back and check. Quote Link to comment Share on other sites More sharing options...
bsmither Posted April 1, 2016 Share Posted April 1, 2016 The grey box (for Foundation, other "No Image Available" images for other skins) is what shows when, for whatever reason, CubeCart has not or cannot associate a source image to a product. Making this association happens in the Add/Edit Product screens in admin. In another post, you mentioned having difficulty getting an image uploaded and/or associated with a product. Once that gets solved, CubeCart will be able to process the image. In my experience, I have seen JPG images created in the CMYK colorspace. Only high-end graphics and layout packages (InDesign, Quark, Photoshop) are able to handle that colorspace. Other utilities (including PHP's GD library) propably can only work with JPGs in the RGB colorspace. It's a longshot, but check where you are getting your product's source images from. Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted April 1, 2016 Share Posted April 1, 2016 Also, can you see the images via FTP or cpanel? Quote Link to comment Share on other sites More sharing options...
jka Posted April 1, 2016 Author Share Posted April 1, 2016 I can't see them via FTP or Cpanel. It doesnt seem to upload. I also tried downloading a stock image from the cube cart website and tried to upload it. No charm. I can try to restart the web server to kick out any gremlins hanging out there. I just tried to upload another image with the image upload screen. I hit Save and it said, image uploaded successfully. When I go to the images file manager tab,"No files found" Quote Link to comment Share on other sites More sharing options...
bsmither Posted April 1, 2016 Share Posted April 1, 2016 In reviewing your site, I see that your web server is announcing itself as "nginx" and the site is powered by PleskLin. I agree that this is still a common-enough server environment, but it's not a widely common environment. With what little experience I have with commercial hosting packages, I might be suspicious that nginx might be used in overly rigid hosting plans. Plans that may have severely limited the size of POSTed uploads, or other settings that interfere with CubeCart operations. You now say you can restart the web server. Apparently Plesk lets you do this? Are you also able to manage the web server config file? If so, maybe a careful analysis of that config file may reveal the reason why you are having issues with uploading image files via POST. Quote Link to comment Share on other sites More sharing options...
jka Posted April 1, 2016 Author Share Posted April 1, 2016 You may be on to something here. I am going to check the php settings on the server. The only part confusing is that it says images uploaded successfully. Let me check the php config. Quote Link to comment Share on other sites More sharing options...
bsmither Posted April 1, 2016 Share Posted April 1, 2016 It should be the nginx config. If nginx is configured to log access errors, such as POSTs being to large, the clues would be in that error log file. On the other hand, a recent conversation revealed (using CubeCart's admin, PHP Info screen) that PHP's 'max_input_vars' was set at 100 (default is 1000). This caused numerous problems updating settings. Quote Link to comment Share on other sites More sharing options...
jka Posted April 1, 2016 Author Share Posted April 1, 2016 The funny thing is that the message after uploading an image it says "file successfully uploaded". It then is not found, goes into an abyss. Quote Link to comment Share on other sites More sharing options...
bsmither Posted April 1, 2016 Share Posted April 1, 2016 Cubecart's FileManager set of functions (called a 'class') will use PHP's trigger_error() function. Unfortunately, the type of error used (E_USER_WARNING) will not get logged in CubeCart's admin Error Log, System Error Log tab listing. We can make a small edit that will log that type of error, thus showing if the FileManager actually had any problems with receiving, validating, and/or moving the uploaded file from PHP's 'file_uploads' setting and/or 'upload_tmp_dir' setting. In the file /classes/debug.class.php, near line 440, find: if($log) { $this->_writeErrorLog($error, $type); } Change to: if(true || $log) { $this->_writeErrorLog($error, $type); } This forces the logging to happen. But it will log everything! So, restore the edit when (if) we find a clue in CubeCart's Error Log. Also, we know CubeCart isn't perfect. You may get a message saying the upload was successful, but while that may be true, there may also be problems elsewhere caused by unanticipated server environments. Quote Link to comment Share on other sites More sharing options...
jka Posted April 1, 2016 Author Share Posted April 1, 2016 You are an amazing man. oday, 17:53 [Warning] //classes/filemanager.class.php:685 - move_uploaded_/images/source/image001.jpg) [function.move-uploaded-file.php]: failed to open stream: No such file or directory Today, 17:53 [Warning] /classes/filemanager.class.php:685 - move_uploaded_file() [function.move-uploaded-file.php]: Unable to move '/tmp/phpj3S2hW' to '/images/source/image001.jpg' [Warning] classes/filemanager.class.php:686 - chmod() [function.chmod.php]: No such file or directory Today, 17:53 [Warning] -/sources/products.index.inc.php:362 - Invalid argument supplied for foreach() Today, 17:52 [Warning] /includes/lib/smarty/sysplugins/smarty_resource.php:733 - filemtime() [function.filemtime.php]: stat failed for /cache/skin/13280168f0b6f095c48216a7e08cfa924e90da43.file.maintenance.index.php.php Quote Link to comment Share on other sites More sharing options...
bsmither Posted April 1, 2016 Share Posted April 1, 2016 We can ignore the "Stat Failed" message. Unable to move '/tmp/phpj3S2hW' to '/images/source/image001.jpg' That looks interesting. Remind us the exact version of CC6 you are running. Ah! I see CC5216. Quote Link to comment Share on other sites More sharing options...
jka Posted April 1, 2016 Author Share Posted April 1, 2016 I have to thank you again for helping me find the error. So, in the CC5216, the folder "source" is completely missing. So, I created the folder and all is good now. Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted April 1, 2016 Share Posted April 1, 2016 WOW! Happy for you that Bsmither was able to help you out! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.