How to fix the Image Caption bug in WordPress 3.7.

If you upgraded to WordPress 3.7 (released yesterday), you may have encountered an issue while inserting a picture in a post with a caption via the Visual editor. The problem is related to a small bug in a script (UglifyJS), and at they are already fixing it.

You can put a temporary fix adding this instruction at the bottom of your wp-config.php file, just before the line /* That's all, stop editing! Happy blogging */.

 /* Temporary fix for Caption Bug in WP 3.7 */  
 define(‘SCRIPT_DEBUG’, true);  

If do not feel like touching the wp-config.php, there is no reason to fret. The patch should be available for downloading or upgrading from the Admin area before the end of the weekend. If your installation of WordPress 3.7 allows automatic upgrades, you may not even see this specific bug and wake up on Monday morning and finding that your site stepped forward to 3.7.1 by itself. And that is one of the greatest features of the new core.

More details at