ms-files.php required ob_clean() and flush()
|Reported by:||pj_mfc||Owned by:||westi|
|Cc:||wordpress@…, kpayne@…, ipstenu@…, dragunoff@…|
I recently migrated a development wp 3 multisite install to 'live' mode for a site launch. One problem I had is that images served out of /files stopped working. Everything looked fine as far as the response / headers, but the image would open up as corrupted.
After quite a bit of troubleshooting, the problem went away when I added ob_clean() and flush() calls to ms-files.php just before the readfile($file) call at the end of the file. Perhaps this is due to a problem elsewhere in my site, but I'm creating this bug so someone can decide if adding the buffer flush would be a reasonable addition to the codebase. It seems like this is the recommended way of doing things according to the sample code here:
Change History (18)
- Keywords needs-patch added
- Milestone changed from Awaiting Review to Future Release