Browser title script ignoring is_page /else conditional [closed]

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center. Closed 9 years … Read more

How to display dynamic content in start_lvl function

I am creating a custom nav walker but having trouble outputting parent menu item title in start_lvl function. I want to output it right after the <div class=”dropdown”> in the following start_lvl function. function start_lvl(&$output, $depth = 0, $args = array()) { $indent = str_repeat(“\t”, $depth); if ($depth == 0) { $out_div = ‘ <div … Read more

How to filter out post type meta?

I have used this code to filter out the post type and it works fine when showing filtered results: add_filter(‘wpseo_title’, ‘vehicle_listing_title’); function vehicle_listing_title( $title ) { if ( ‘vehicles’ != $post->post_type ) { $location = get_the_terms($post->ID, ‘vehicle_location’); $model = get_the_terms($post->ID, ‘vehicle_model’); $title=””; if($model && $model[0]) $title .= $model[0]->name . ‘ used’; else $title .= ‘Used’; … Read more

Add Category name to Post Title (h1)

How to add Category name to post title (H1)? “PostTitle + CategoryName”? My h1 post title code: <?php the_title( ‘<h1 class=”entry-title”>’, ‘</h1>’ ); ?> 2 Answers 2 I would work the code arround and do something like this. <h1><?php echo get_the_title(); ?> – <?php the_category(‘, ‘); ?></h1> get_the_title(); Retrieve post title. the_category(‘, ‘); Displays links … Read more