Uploaded images disappear after loading if using compression w/Apache
|Reported by:||ctsttom||Owned by:|
|Component:||Upload||Keywords:||dev-feedback needs-testing needs-refresh|
I have found an issue between WordPress (Multisite) + Google Chrome (Mac) which I think appeared on my sever when I enabled compression a few months ago, but could never reproduce because it only happens with images managed by a Multisite WordPress install, not static images.
With images that are static Apache sends the file and calculates the Content-Length its self so these images work fine but if you access a file uploaded to WordPress it uses the .htaccess redirect so the image requests are sent via ms-files.php for what ever reason.
The problem is that WordPress decides to calculate its own Content-Length header in the HTTP Response which means that security conscious browsers like Google Chrome freak out when the data they receive is less than they we're told by Apache and they resultantly disable the image.
The Content-Length calculation comes on line 43 of ms-files.php I don't know why its needed because Apache seems to sort it out automatically if you don't send your own header, in fact most of the file seems like an unnessisary load of processing, perhaps it needs reviewing but this is a major issue as it is a growing browser, on a growing platform.
Here is a great video of it in action: http://www.screencast.com/t/cUYKSegW0N
This issue has been repeatedly reported on the forum:
Please fix this asap!
Change History (29)
4 years ago
- Summary changed from Uploaded images dissapear after loading if using compression w/Apache to Uploaded images disappear after loading if using compression w/Apache