Get category link

0
<?php
// Get the ID of a given category
$category_id = get_cat_ID( 'Category Name' );

// Get the URL of this category
$category_link = get_category_link( $category_id );
?>

<!-- Print a link to this category -->
<a href="<?php echo $category_link; ?>" title="Category Name">Category Name</a>
Loading related posts...

0 comments:

Post a Comment

2010 WEBSITE20. All rights reserved.