Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I am having a strange issue with the built in wordpress image editor. I have no problem uploading files or preforming any other media functions. The only thing I seem to be unable to do is utilize the image "edit" capabilities (the area where you can crop, resize, rotate...)

When I click on "edit" for an image I see the editor and I see the thumbnail on the right, wordpress just won't show me the actual image in the main area and thus I can't utilizing any of the editing capabilities.

I am assuming this must be some type of JavaScript conflict however I not sure the best way to diagnose this other than what I have already done (disabling all plugins and ensuring no functions.php file is modifying a setting or including other javascript).

How can I diagnose this issue to see what might be going wrong?

share|improve this question
    
It could also be a PHP issue. If you don't have the right modules or version of PHP installed, WordPress is built to "decompose gracefully" ... meaning that certain bonus features become disabled if your system's setup doesn't support them. Can you run phpinfo (php.net/manual/en/function.phpinfo.php) on your site and report back what your system's using? –  EAMann Sep 10 '10 at 14:22
    
Open the page in Firefox with Firebug Add-On installed. Check for Javascript Errors in the log. Please report back if you have any Javascript Errors. –  hakre Sep 14 '10 at 17:40
1  
@eamann @hakre Thanks guys - i ended up figured out what was going on through a great deal of trial and error. See my attached answer in case your interested. –  NetConstructor.com Sep 14 '10 at 20:19

2 Answers 2

up vote 4 down vote accepted

I have actually managed to resolve my own problem. For anyone else that might ever read this the problem which caused this was that my functions.php file had a closing

?>

at the very end. For whatever reason this is what cause the issue and by removing this last line it was working again.

share|improve this answer
2  
You might have had some characters (whitespace) after that ?>. See core.trac.wordpress.org/ticket/12307 and core.trac.wordpress.org/ticket/10633 –  hakre Sep 14 '10 at 22:17
    
VERY TRUE... THANKS –  NetConstructor.com Sep 15 '10 at 3:22
    
I had the same problem - and this solution (removing the ?>) at the end of my theme functions.php worked for me, great! Thanks very much for this advice. –  user4815 Apr 21 '11 at 10:28
1  
I have this exact problem right now however I wasn't as lucky as you, I have removed any closing ?> tags and whitespace from my functions file and all files that I have included into my functions file and I still have the problem. Very frustrating. I have no javascript errors either –  jasondavis Mar 16 '12 at 6:51
    
This helped me too. I was wondering what the issue was. Although, it was not function.php for me. I had to remove them (?>) in all the php files I was including. –  Prakash Raman Mar 27 '13 at 8:01

Yes, the problem is the PHP closing tag (?>) in functions.php.

However, if in functions.php there are many inclusions which in turn include other PHP files, it is unthinkable to remove all PHP closing tag in all files.

So, my advice is add in the first line of functions.php the php function ob_start() and in the last line ob_end_clean() by removing the closing PHP tag.

Everything will work perfectly.

share|improve this answer
1  
You'd suggest output buffering to mask the problem instead of correcting the PHP? –  s_ha_dum Jun 8 '13 at 16:09

protected by Community Sep 23 '13 at 13:29

Thank you for your interest in this question. Because it has attracted low-quality answers, posting an answer now requires 10 reputation on this site.

Would you like to answer one of these unanswered questions instead?

Not the answer you're looking for? Browse other questions tagged or ask your own question.