[Resolved] Invalid Header
I’m afraid I can’t reproduce this error, even on an empty WordPress installation.
What version of WordPress are you running?
I’m using WordPress 3.8.1.
I’ll check if this plugin conflicts with another one and will report.
Ok, I Install the plugin and activate it from the installation process – I get the error.
I install the plugin and go back to plugin-page and activate it from there – No error.
May still be something with a different plugin or not, but this way I can still use it.
I had the same problem: I got an invalid error when trying to activate immediately after installing, but if I went to the plugin page I could activate there.
Here’s my rig:
[Moderator Note: Please post log files between backticks or use the code button.]
If you didn’t install from the plugins page, where were you installing from?
Were you using WordPress’s FTP install method?
I installed from the wp-admin plugin page. Searched for the plugin by name and clicked the install link on the wp-admin page. WordPress said it installed. I clicked the activate link on the wp-admin page. WordPress said it had an invalid header.
Next I went to the plugin page in wp-admin. I was able to activate it from there.
Sorry, but I’m not following the difference between the “wp-admin plugin page” and the “plugin page in wp-admin”
What richpav describes is 100% what I am facing.
– Install from within WordPress and activate and the end of installation -> header error
– install from within WordPress and do not activate, but return to plugin-page (install, but let the plugin deactivated). Activate it now from the list of inactive plugins -> no problem.
Ok, so you are installing via WordPress’s FTP method straight from the plugin directory. This is what I was trying to understand.
I don’t currently have an FTP server running anywhere, but I’ll look into what is required to support this install method and hopefully fix it.
Dumb question perhaps, but can you install other plugins directly from the repository this way?
just to clarify:
– I install your Plugin from http://[myWordpressDomain]/wp-admin/plugin-install.php (From the Dashboard it’s Menu Plugin > Install)
– Yes other plugins work this way.
– The only plugins form richpav list taht I use too, is Contact Form 7.
I just tried the direct install method by changing the
FS_METHODto ‘direct’ rather than the default FTP – and I got no activation error when clicking activate straight away.
I need to find what bit of code the error is coming from. Searching for the error message “this plugin cannot be activated” in the WordPress codebase brings up nothing in my install. Is this the exact wording of the error?
Can you clarify whether the exact error text is in fact “The plugin does not have a valid header.” As this is a known error message.
Yes, that was the error message. I tried twice to install the plugin and got the same result.
Also, does Loco Translate detect translation files the exactly same way as WordPress does? I should create another topic instead of going off on a tangent…
re translation files. yes please open another thread if you think there’s a problem there.
re “invalid headers”
There are a number of things that cause this —
One cause is incorrectly nested folders inside the zip file. This shouldn’t be the case because WordPress is zipping it themselves. However, I did have a problem with an accidental extra folder, but this was deleted. If you see a folder called “trunk” inside “loco-translate” folder then this might explain it, but it has since been removed.
Another cause is double line spacing in PHP files caused by DOS line breaks. These can appear when using FTP if the FTP server is set to translate them. However, the fact that a second attempt to install the plugin does work, makes this an unlikely cause. But I’m not ruling it out.
Another cause is when the “Tested up to” header contains a lower version of WordPress that you’re using. Loco-translate has this set to 3.8, but this should cover 3.8.1 – I’ve tried it myself and I don’t get an error.
I’m afraid I’m not much closer to working this out. As the plugin does install, I can’t put this to the top of my priority list. I’ll update the thread if I solve this (i.e. if I can reproduce this) but I’m hoping it may “fix itself” in the next release as I’ve not had any reports before this version, and I suspect it may be related to the extra folder issue.
- The topic ‘[Resolved] Invalid Header’ is closed to new replies.