We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hey,
we get a chdir error, when the array contains only one url. With two or more the zip file is generated without any problems.
Error: Alchemy\Zippy\Exception\RuntimeException: Unable to chdir to https://www.google.de/images/branding/googlelogo/2x
https://www.google.de/images/branding/googlelogo/2x
NOT WORKING: $file = ['https://www.google.de/images/branding/googlelogo/2x/googlelogo_color_272x92dp.png']; $archiveZip = $zippy->create('archive.zip', $file, false);
WORKING: $file =['https://www.google.de/images/branding/googlelogo/2x/googlelogo_color_272x92dp.png','https://www.google.de/images/branding/googlelogo/2x/googlelogo_color_272x92dp.png']; $archiveZip = $zippy->create('archive.zip', $file, false);
Any help is appreciated.
Kind regards Michael
The text was updated successfully, but these errors were encountered:
Hello,
I investigated and the error seems to be caused by this line of code: return isset($data['path']); https://github.com/alchemy-fr/Zippy/blob/master/src/Resource/Resource.php#L114
return isset($data['path']);
Even for a path that is without any doubt NOT local the path index will be set. (You can test this here: http://sandbox.onlinephpfunctions.com/code/29fbfd20b141347ec613740ab7b7b039c95cec1a )
path
parse_url() does not seem to be the right choice here. I guess the most basic approach would be to check if the path contains "://".
parse_url()
://
Sorry, something went wrong.
No branches or pull requests
Hey,
we get a chdir error, when the array contains only one url.
With two or more the zip file is generated without any problems.
Error: Alchemy\Zippy\Exception\RuntimeException: Unable to chdir to
https://www.google.de/images/branding/googlelogo/2x
NOT WORKING:
$file = ['https://www.google.de/images/branding/googlelogo/2x/googlelogo_color_272x92dp.png'];
$archiveZip = $zippy->create('archive.zip', $file, false);
WORKING:
$file =['https://www.google.de/images/branding/googlelogo/2x/googlelogo_color_272x92dp.png','https://www.google.de/images/branding/googlelogo/2x/googlelogo_color_272x92dp.png'];
$archiveZip = $zippy->create('archive.zip', $file, false);
Any help is appreciated.
Kind regards
Michael
The text was updated successfully, but these errors were encountered: