• Resolved joah

    (@joah)


    Hi!

    How do I give a style to <?php the_category(',') ?>, such as color font-family, etc?

    If I use this variable, I cannot control how it looks…
    See the source of my index page for details.

    Thanks for your input!

Viewing 3 replies - 1 through 3 (of 3 total)
  • Have you tried:
    <span id="spec-cat"><?php the_category(','); ?></span>
    ?

    Style #spec-cat as any other element.

    Thread Starter joah

    (@joah)

    Yes I have the whole thing inside a DIV with an ID that is styled in a stylesheet, but not a SPAN –does that matter?

    It is this:

    <div class="fp_post_bsr_details" style="float:right;">
         <?php the_time('F dS, Y'); ?> |
         <?php _e("Tags: "); ?><?php the_tags('', ', ', ''); ?> |
         <?php _e("Category: "); ?><?php the_category(',') ?> |
         <?php comments_popup_link(__('Comments (0)'), __('Comments (1)'), __('Comments (%)')); ?> |
         <?php _e("Author: "); ?><?php the_author(',') ?>
    </div>

    And in the stylesheet is says:

    .fp_post_bar_details a {
    	font-size:10px;
    	color:#999999;
    	font-weight:bold;
    	text-decoration: none;
    	border: 0px;
    	}
    .fp_post_bar_details a:hover {
    	font-family:Arial, Helvetica, sans-serif;
    	font-size:10px;
    	color:#CCCCCC;
    	font-weight:bold;
    	text-decoration: none;
    	border: 0px;
    	}

    What am i missing?

    Thread Starter joah

    (@joah)

    ppffffff while posting all this i spot a typo!
    sorry to have wasted your time….

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘How to apply style to the_category(‘,’) ?’ is closed to new replies.