What CSS Selector for Category Name Added At Top of Each Category Page?
The discussion on how to put the category name at top of a category page, found at http://forum.bytesforall.com/showthread.php?t=2101 , was very helpful. Following these instructions, we successfully made the Category name show at the top of each Category Page.
However, I have not been able to find the right CSS selector to change the color of the Category Name <h3> headings as they appear at top of the Category pages. Help would be much appreciated! Many thanks! |
What have you tried?
Do you have a link to the site? Did you try adding !important in your CSS? |
Hi Larry,
We have tried: #single_cat_title { color: #357ec7 } and h3 + p { color: #357ec7 } Any other ideas? I will send you a message with a link to our site. Thanks! |
change the '<h3>' to '<h3 class="single_cat_title">' and then use that as the class identifier
|
Thank you for the reply, Juggledad. Just to be sure I understand: Do you mean to change the code I added in index.php, after <?php get_header(); ?>, so that
rather than <?php if ( is_category() ) {?><h3><?php single_cat_title(''); ?></h3><?php } ?> it will read as follows: <?php if ( is_category() ) {?><h3><?php single_cat_title(''); ?><h3 class="single_cat_title"><?php } ?> Then enter a CSS insert as follows: .single_cat_title { color: #357ec7; } Is that what you meant? Just want to be sure I have it right before implementing. Many thanks! |
Oops!
The code should rather be: <?php if ( is_category() ) {?><h3 class="single_cat_title"><?php single_cat_title(''); ?></h3><?php } ?> Is that correct? Would that work with a CSS selector as follows: h3 .single_cat_title { color: #357ec7; } Meanwhile, I just changed all h3 headers to that color as follows: h3 {color: #357ec7;} But, would rather use CSS to specifically select the Category page titles. Would the above do it? Many thanks! |
yup. but no space betweenteh h3 and the .single_cat_title so it should be
h3.single_cat_title { color: #357ec7; } |
All times are GMT -6. The time now is 05:29 PM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.