Wordpress Categories and Tags not linking
I am not sure why this issue has risen up, never had this problem in any of my other blogs that I have done. But perhaps someone is able to shed some light on this.
I have a list of posts. TITLE | CATEGORIES | DATE
The title links correctly, But the CATEGORIES do not. My Code for displaying the category is:
<li class="category"><?php the_category(', ') ?></li>
When I click the category link it displays 404 not found but there is a URL issue that comes in:
http://domain.com/categoryName SHOULD BE http://domain.com/category/categoryNameI do have the exact same issue with the TAGS but I d开发者_Python百科on't know what to reference for the TAG feature.
I used the Default Widget for "most popular tags" and it just doesn't link properly no matter what... and it too has the url of:
http://domain.com/tagName
Any help would be appreciated.
The function the_category()
only returns the category names, where are you generating the href?. Wherever you're specifying the url in your code, you should just be able to add /category/
. I'd need to see more code to be more helpful.
Also, the_category() will return all the categories, so if you have more than one category, it might screw up your url more. Again, would need to see more code.
Sorry about this post, it was an issue with the previous theme-author. He removed the the code for the categories.
精彩评论