Remove only gallery CSS in twentyten, leaving the gallery div classes and id intact. see #9015

git-svn-id: http://svn.automattic.com/wordpress/trunk@13552 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
nacin 2010-03-02 18:08:14 +00:00
parent 95623b4ce5
commit a17a92274b
1 changed files with 2 additions and 2 deletions

View File

@ -139,8 +139,8 @@ endif;
// Remove inline styles on gallery shortcode
if ( ! function_exists( 'twentyten_remove_gallery_css' ) ) :
function twentyten_remove_gallery_css() {
return "\t\t<div class='gallery'>\n\t\t";
function twentyten_remove_gallery_css( $css ) {
return preg_replace( "#<style type='text/css'>(.*?)</style>#s", '', $css );
}
endif;
add_filter( 'gallery_style', 'twentyten_remove_gallery_css' );