How to test If a post has a particular term

You can test if a post has a particular term assigned to it with the has_term function. E.g. if ( has_term( ‘term-slug’, ‘taxonomy-slug’ ) ) { // do stuff } With this you can test if your “post” has a particular “term” ( aka if your “product” has a particular “product_cat” )

Unsetting post_tag taxonomy breaks term description for other taxonomies

Try using this function to avoid your problem: function sld_unregister_taxonomy_from_object_type($taxonomy, $object_type) { global $wp_taxonomies; if ( !isset($wp_taxonomies[$taxonomy]) || !get_post_type_object($object_type) ) return false; foreach (array_keys($wp_taxonomies[$taxonomy]->object_type) as $array_key) { if ($wp_taxonomies[$taxonomy]->object_type[$array_key] == $array_key) { unset ($wp_taxonomies[$taxonomy]->object_type[$array_key]); return true; } } return false; } e.x.: function mwm_unregister_taxonomy(){ sld_unregister_taxonomy_from_object_type( ‘post_tag’, ‘post’ ); } add_action( ‘init’, ‘mwm_unregister_taxonomy’);

Image “description” and SEO within WP

The alt tag is the description for an image… This tags exists since google cant “read” the image. That is why we describe the image for googe / bing / etc… the alt tag should no be longer then 3-5 words max (3 is better). The title tag is not a must unless you wish … Read more

How do I begin debugging where the description meta tag is set for my categories?

in seo.php in the custom folder line 73 global $suf_seo_meta_description, $wp_query; if (is_home()) { $description = $suf_seo_meta_description; } else if (is_singular()) { $description = suffusion_get_post_meta($wp_query->post->ID, “suf_meta_description”, true); if (empty($description)) { // Check the old meta field $description = suffusion_get_post_meta($wp_query->post->ID, “meta_description”, true); } if (empty($description) && is_front_page()) { $description = $suf_seo_meta_description; } } else if (is_category() … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)