http://simplytest.me/project/fontello/7.x-1.0-beta1
http://s087c525655120c1.s2.simplytest.me/admin/appearance/fontello
When trying to upload a bundle, I'm getting this error:
Warning: ZipArchive::extractTo() [ziparchive.extractto]: Unable to access public://fontello/fontello-341cf159 in ArchiverZip->extract() (line 112 of /home/s087c525655120c1/www/modules/system/system.archiver.inc).
| Comment | File | Size | Author |
|---|---|---|---|
| #5 | Screen Shot 2013-03-01 at 8.39.32 AM.png | 312.9 KB | markhalliwell |
| #4 | 1930464-fontello-archive-issues-4.patch | 3.7 KB | markhalliwell |
Comments
Comment #1
patrickd commentedThanks for reporting this!
I've now spend some time on trying around with file permissions, but it may be an issue with the fact that all simplytest.me sites run with safe mode on, which is good for security but bad for handling files.
Not sure how to solve this yet, sorry!
Comment #2
patrickd commented(btw, without admin menu it is nearly impossible to find a link to admin/appearance/fontello, I'd suggest defining it as local task instead of a normal menu item)
Okay it seems that Drupals ZipArchiver uses PHP's standard ZipArchive->extractTo which only works for safe_mode=Off when stream wrappers are used.
While for tar.gz files Archive_Tar is used which does not make use of any PHP specific extraction function - and therefore works with safe_mode=On
The problem with ZipArchive is known: #1270862: ArchiverZip::extract() needs workaround for open_basedir & stream wrappers
chx suggested to use drupal_realpath() as parameters for extraction as workaround:
update_manager_archive_extract(drupal_realpath($file->uri), drupal_realpath($archive_destination));Maybe you can try that out, not sure whether it will help
Comment #3
markhalliwellAh yes, I noticed that menu registry foobar on my part lol I fixed it, just haven't pushed it yet.
And thanks for the update. I'll definitely try that method and let you know how that works out :) Thanks for the feedback!
Comment #4
markhalliwellI'm gonna move this to Fontello's issue queue and provide a patch here to test against simplytest.me.
Comment #5
markhalliwellAwesome :) That did it! Thanks again for helping me get on the right path here!

Comment #6
patrickd commentedyeah, that's great! :)
Comment #8
leenyx commentedHow is this going?
how it's possible that this module doesn't allow importing the settings in zip format when the service (fontello) exports to zip?
The current quality of drupal modules is reflected on this module, just doesn't work!
Comment #9
patrickd commentedworks for me? It does allow zip files, I just tried it.
can you describe what exact issue you have? error messages? how to reproduce?
"just doesn't work" is not helpful here
Comment #10
markhalliwellAt first I thought this might pertain to the major recent changes in Fontello, but I too was able to import an icon bundle just fine. Besides, this issue originally pertained to how http://simplytest.me seemed to fail when trying to extract the archive file. I was able to resolve this in the Fontello module long ago. This fix has been transferred to the Icon API since then.
From #2:
The current quality of drupal users (who don't contribute any actual code btw) is reflected in this issue, they just don't read (and complain about non-related issues)! Sad.
Comment #11
rt3me commentedI wonder if my issue could be related. I am trying to import a fontello package and the file upload dialog says:
Files with the following extensions are allowed: tar tgz gz bz2
After failing to figure out why it will not allow zip files to be uploaded (it does throw an error if I try), I attempted extracting the zip file and creating a tgz. which resulted in this error on attempted upload:
Fatal error: Call to undefined method Archive_Tar::close() in /home/makeweb/public_html/wcbc/sites/all/modules/contrib/icon/includes/import.inc on line 134
Two quesitons:
Could something about my server setup or something else be preventing zip files to be an extension available for upload?
What's up with the tar error?
I don't think safe_mode should be an issue because my server is on php 5.4.26 and php.net says that safe_mode has been removed from php 5.4 and my php.ini has the safe_mode = Off line commented out.
Thanks in advance for any help you can give! and thanks for the great work on this module!
Comment #12
candelas commented@robturner it looks like the problem comes from icon api. I found a temporal solution importing with icon api beta3 and then using the last dev. You can see here https://drupal.org/node/2198371
Comment #13
robbdavis commentedre: @rt3me's issue. I had the same problem; icon api did not show the zip file as an upload problem. This was an issue with my local server set up. I needed to install the php zip package.
sudo apt-get install php5.6-zip
Or, if you're using DrupalVM like I am, just add php5.6-zip to the extra packages list then run "vagrant provision".