Originally Posted by
DrByte
Why is the file coming in named as ".0" ? If you want to allow *.0 files, add the .0 to the list of supported file types.
Unfortunately, the fix for ZC 1.5.6c, specifically set the check against items in the maximum configuration area to require being an integer. This was identified "later(?)" as being too stringent. A result of that is that when the error message for the upload class is generated:
Code:
$this->message_stack(ERROR_FILETYPE_NOT_ALLOWED . ' .' . implode(', .', $this->extensions), 'error');
It somewhat seems as if one has entered an extension of "0" or ".0", but as can be seen in the above message, the extension list is "pulled" from and a period is applied as a prefix. Therefore, even though a valid extension (or extension list) was present at some point, pre-processing of the extension list in ZC 1.5.6c (without the additional "fix" provided in the newer ZC v156 branch) causes the extension(s) to be 0 and not matching the attempted upload unless someone has actually renamed their file to have a ".0" extension. Could do that I guess if they left the expected extension before that. So a file called mypic.jpg could be stored on their own computer as mypic.jpg.0 and the store owner would have to remove the ".0" to get back to the original filename...
See: https://github.com/zencart/zencart/b...ead.php#L24-25
As compared to:
https://github.com/zencart/zencart/b...ead.php#L24-25
For those not seeing the lines being highlighted after following the above link(s), the lines in question are 24 and 25, specifically the differences in line 25...
Bookmarks