Title: Hyperlink for single_cat_title
Last modified: August 19, 2016

---

# Hyperlink for single_cat_title

 *  Resolved [nemci7v](https://wordpress.org/support/users/nemci7v/)
 * (@nemci7v)
 * [16 years, 2 months ago](https://wordpress.org/support/topic/hyperlink-for-single_cat_title/)
 * I tried using some other codes I found in codex but none display the correct 
   category. I’m displaying a “posted in single_cat_title” for a loop. Other codes
   display a different category.. Is there a way to hyperlink the one that works
   for me?

Viewing 3 replies - 1 through 3 (of 3 total)

 *  [Mark / t31os](https://wordpress.org/support/users/t31os_/)
 * (@t31os_)
 * [16 years, 2 months ago](https://wordpress.org/support/topic/hyperlink-for-single_cat_title/#post-1406050)
 * You could do..
 *     ```
       <?php $link = get_category_link( get_cat_ID( single_cat_title('',false) ) ); ?>
       <a href="<?php echo $link; ?>" title="<?php single_cat_title('') ?>"><?php single_cat_title() ?>
       </a>
       ```
   
 * ..hope that helps.
 *  Thread Starter [nemci7v](https://wordpress.org/support/users/nemci7v/)
 * (@nemci7v)
 * [16 years, 2 months ago](https://wordpress.org/support/topic/hyperlink-for-single_cat_title/#post-1406052)
 * it does thanks! Works perfectly 🙂
 *  [Mark / t31os](https://wordpress.org/support/users/t31os_/)
 * (@t31os_)
 * [16 years, 2 months ago](https://wordpress.org/support/topic/hyperlink-for-single_cat_title/#post-1406092)
 * You’re welcome.. 🙂

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Hyperlink for single_cat_title’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 3 replies
 * 2 participants
 * Last reply from: [Mark / t31os](https://wordpress.org/support/users/t31os_/)
 * Last activity: [16 years, 2 months ago](https://wordpress.org/support/topic/hyperlink-for-single_cat_title/#post-1406092)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
