Skip to content

Commit

Permalink
Filter content_width wider for full-width-page.php template.
Browse files Browse the repository at this point in the history
  • Loading branch information
lancewillett committed Jun 24, 2012
1 parent b9612c3 commit 1f5a9ff
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion source/functions/functions.php
Expand Up @@ -432,4 +432,15 @@ function twentytwelve_body_class( $classes ) {

return $classes;
}
add_filter( 'body_class', 'twentytwelve_body_class' );
add_filter( 'body_class', 'twentytwelve_body_class' );

/**
* Adjust $content width for full-width template.
*/
function twentytwelve_content_width() {
if ( is_page_template( 'full-width-page.php' ) ) {
global $content_width;
$content_width = 960;
}
}
add_action( 'template_redirect', 'twentytwelve_content_width' );

0 comments on commit 1f5a9ff

Please sign in to comment.