Opened 2 years ago
Closed 23 months ago
#17355 closed feature request (duplicate)
Zip install should cope with version files and files zipped at folder level
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | Upgrade/Install | Version: | |
| Severity: | normal | Keywords: | |
| Cc: |
Description
Currently if someone zips a plugin at the folder level and the recipient of the zip file uses the zip install option, the plugin will get installed a layer too deep and activation fails with an 'invalid headers' message.
The unzip process should check whether there are folders, but no files (allowing multiple would allow multiple plugins in one go) If no files, then assume that the folders are plugin folders and insert them direct into the plugins folder.
ONLY If there are files not just a folder, then create the plugin folder using the zip file name (unless someone can think of another way to work out whether the zip file has version numbers or not.
Ideally one should safely be able to name zip files with version numbers for better tracking of versions of a plugin. eg:
pluginname1.1.zip
would contain
pluginame folder OR 1 file pluginname.php
and would get unzipped to exactly that within the plugin folder.
Current functioning would unzip and install to a folder called
pluginame1.1 and if the recipent got a plugin update and zip installed that, it would create another folder
pluginname1.2
and attempt to activate a second instance of the plugin.
Personally I always use ftp, but there are more and more people using wordpress who are unfamiliar with ftp. The Zip installer should be more robust so they struggle less.

I think this was fixed - see http://core.trac.wordpress.org/ticket/15191