Estimated Time to Complete: 5 Minutes
If you are trying to call the category name in WordPress by the tag the_category( ‘, ‘ ); a link is automatically created to the
Using the above code you’ll get only the Category Name.Category Archive page. If you would like to call only the category name without linking the Category archives page to it.
For Example: If you want to show a Subscribe box which says, “Send me newsletters related to ‘WordPress‘ “. Using the default WordPress Category tag will link it to the Category Archive Page.
Use the code below for calling only the Category name:
$category = get_the_category();
After using the above code result should look like this: “Send me Newsletters related to ‘WordPress’”