Return to Snippet

Revision: 16060
at July 24, 2009 16:57 by dsheetz


Initial Code
if(is_category()) {
	$cat = get_query_var('cat');
	$yourcat = get_category($cat);
	echo "the slug is" . $yourcat->slug;
}

Initial URL
http://www.bestwpthemez.com/wordpress/code-to-get-current-category-slug-in-wordpress-blog-1434/

Initial Description

                                

Initial Title
Wordpress Get Category Slug

Initial Tags
php, wordpress, category

Initial Language
PHP