Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dynamic Wrappers: Set Custom Body Class Names #9

Open
bhubbard opened this issue Nov 4, 2015 · 0 comments
Open

Dynamic Wrappers: Set Custom Body Class Names #9

bhubbard opened this issue Nov 4, 2015 · 0 comments

Comments

@bhubbard
Copy link
Contributor

bhubbard commented Nov 4, 2015

I suggest we set better body class names for the dynamic wrappers as many such as the page id don't really apply or make sense.

// This breaks Genesis, due to body class hooks (needs if statement)
function idxbroker_wrappers_wpbody_class_names( $classes) {
    if ( 'idx-wrapper' == get_post_type() ) {
            return array('idxbroker idxbroker-dynamic-wrapper dynamic-wrapper-'.get_the_title().'' );
        } else {  }
}
add_filter( 'body_class', 'idxbroker_wrappers_wpbody_class_names' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants