Show metabox only for homepage

is_front_page() is only for use on the front-end to tell if the ‘main query’ is for the front page. In a back end context you need to check if the current post ID (which is in the $post passed to your callback function) is the same ID that’s set to be the front page. So … Read more

Trying to get property of non-object in WordPress Breadcrumbs

You need to check if get_the_terms() is actually returning anything. If a post doesn’t have terms in that taxonomy, then $taxonomy_terms won’t actually have any terms in it. If $taxonomy_terms is empty then $taxonomy_terms[0] won’t actually be a term object so trying to access a property on it (->term_id) will throw an error: $taxonomy_exists = … Read more

Override Admin menu icon

One way is to use the admin_menu hook to insert CSS with your selection of menu icons (which use the DashIcons). The googles show this recent result: https://swapnil.blog/2018/06/25/how-to-change-wordpress-admin-icons/ . Here’s some code from there; you’ll just need to figure out the CSS for each menu item – use your Developer inspection tools (F12, usually) to … Read more

Show all tags within a category?

The best way to do that would be to create a custom page template, and make a custom loop that would only display the posts in you specific category and tag. For example: global $wp_query; $args = array( ‘category__and’ => ‘category’, ‘tag__in’ => ‘post_tag’, //Enter tag id for this field (not tah name) ‘posts_per_page’ => … Read more