Body class cleaning
-
Hi there,
I’m looking for the best way to “clean” the body classes generated by WordPress by default, through functions.php. I’ve found an interesting way to do it here:
https://github.com/billerickson/EA-Genesis-Child/blob/master/inc/wordpress-cleanup.php
Getting the following classes :
‘singular’,
‘single’,
‘page’,
‘archive’,
‘admin-bar’,
‘full-width-content’,
‘content-sidebar’,
‘content’,
is already nice but it’s a bit restrictive because I’d like to authorize classes like .page-*** dynamically for every new page created.Is using something like :
$dynamic_pages = "page-". $dynamic_pages;
is a good way to achieve it?Thanks by advance for your help !
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- The topic ‘Body class cleaning’ is closed to new replies.