Changing the menu wrapper

Changing the menu wrapper

class Nav_Walker_Nav_Menu extends Walker_Nav_Menu{ function start_el(&$output, $item, $depth, $args){ global $wp_query; $indent = ( $depth ) ? str_repeat( “\t”, $depth ) : ”; $class_names = $value = ”; $classes = empty( $item->classes ) ?...
Simple Toggl Button

Adding a custom class

function my_class_names($classes) { // add ‘class-name’ to the $classes array if( !is_front_page() ) $classes[] = ‘not-front’; if( is_single() ) $classes[] .= ‘et_full_width_page’; if(($key =...
Changing the name of a post-type in cherry framework 4

Changing the name of a post-type in cherry framework 4

Changing the name of a post-type in cherry framework 4. function wpd_update_taxonomy_args( $taxonomy, $object_type, $args ){ if( ‘portfolio_category’ == $taxonomy ){ // remove this action so we don’t create an infinite loop! remove_action(...