I did more research. It seems that by combining scripts, localization is lost for thickbox.js. In WP 3.5.1, see /wp-includes/script-loader.php, line 182:
did_action( 'init' ) && $scripts->localize( 'thickbox', 'thickboxL10n', array(
'next' => __('Next >'),
'prev' => __('< Prev'),
'image' => __('Image'),
'of' => __('of'),
'close' => __('Close'),
'noiframes' => __('This feature requires inline frames. You have iframes disabled or your browser does not support them.'),
'loadingAnimation' => includes_url('js/thickbox/loadingAnimation.gif'),
'closeImage' => includes_url('js/thickbox/tb-close.png')
) );
When the plugin is enabled with combining on, this localization is not triggered (hence the thickboxL10n undefined errors).
I fixed my issue by adding this to my theme’s functions.php:
function mytheme_thickbox_compression_fix() {
echo '<script type="text/javascript">';
echo "var thickboxL10n = ".json_encode(array(
'next' => __('Next >'),
'prev' => __('< Prev'),
'image' => __('Image'),
'of' => __('of'),
'close' => __('Close'),
'noiframes' => __('This feature requires inline frames. You have iframes disabled or your browser does not support them.'),
'loadingAnimation' => includes_url('js/thickbox/loadingAnimation.gif'),
'closeImage' => includes_url('js/thickbox/tb-close.png')));
echo '</script>';
}
add_filter('wp_footer','mytheme_thickbox_compression_fix',20000001);
It’s a hack that works for now, at least until this issue can be addressed by the developer.