Created
February 22, 2014 10:56
-
-
Save onishiweb/9151992 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Post type class function | |
* @author Adam Onishi <[email protected]> | |
*/ | |
function dig_get_post_type_class( $type = false ) { | |
if( ! $type ) { | |
$type = dig_current_post_type(); | |
} | |
$class = str_replace('dig_', '', $type); | |
$class = str_replace('_', '-', $class); | |
return $class; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment