Title: CSS help
Last modified: August 19, 2016

---

# CSS help

 *  [samueldiener](https://wordpress.org/support/users/samueldiener/)
 * (@samueldiener)
 * [16 years, 9 months ago](https://wordpress.org/support/topic/css-help-8/)
 * Hi everyone,
 * I have what might be a relatively simple question.
    On my main page, [http://www.samdiener.com](http://www.samdiener.com),
   I want ?php the_content() to generate the content in 9px font. Which it does 
   perfectly.
 * However, on subpages, eg. [http://www.samdiener.com/2009/08/creative-networking-for-your-job-search-101/](http://www.samdiener.com/2009/08/creative-networking-for-your-job-search-101/)
   I want the size to be different. However, I am not sure how to render in a different
   size since the template is calling the_content() to generate content in the same
   size as the main page.
 * The code from my template is
 * >  <div class=”topPost”>
   >  <h2 class=”topTitle”>“><?php the_title(); ?>
   > </h2>
   > 
   > <p class=”topMeta”>by <?php the_author_posts_link(); ?> on <?php the_time(‘
   > M.d, Y’) ?>, under <?php the_category(‘, ‘); ?></p> <div class=”topContent”
   > ><?php the_content(‘(continue reading…)’); ?></div> <div class=”cleared”></
   > div> <span class=”linkpages”><?php wp_link_pages(); ?></span><div class=”cleared”
   > ></div> <?php if ( function_exists(‘the_tags’) ) : ?><span class=”topTags”>
   > <?php the_tags(‘_:_‘, ‘, ‘, ”); ?></span><?php endif; ?> <div class=”cleared”
   > ></div> </div> <!– Closes topPost –>
   > <small><?php edit_post_link(‘Edit this entry?’,”,”); ?></small>
   > <div id=”comments”>
   >  <?php if (function_exists(‘wp_list_comments’)): ?> <!–
   > WP 2.7 and above –>
 * Thanks guys!
 * Sam

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

 *  [esmi](https://wordpress.org/support/users/esmi/)
 * (@esmi)
 * [16 years, 9 months ago](https://wordpress.org/support/topic/css-help-8/#post-1181094)
 * In single.php, try changing:
 * `<div class="topPost">`
 * to
 * `<div class="topPost single">`
 * then you can add:
 * `.single p {font-size:npx}
 * where n = the size you want to use on single post pages.
 * Incidentally, try not to set font sixes oin pts . Pts are best kept for documents
   that are to be printed. Set font sizes in px, % or em. They all work better on
   the web.
 *  Thread Starter [samueldiener](https://wordpress.org/support/users/samueldiener/)
 * (@samueldiener)
 * [16 years, 9 months ago](https://wordpress.org/support/topic/css-help-8/#post-1181284)
 * So in style.css, I add:
 * .topPost .single p {font-size:11px}
 * If so, this does not work. However, I am pretty sure this is not correct. Also,
 * just for my reference, what does the “.” before the single mean vs no “.” vs.#
   in css
 * Thanks!
 * Sam
 *  [Peter Boosten](https://wordpress.org/support/users/pboosten/)
 * (@pboosten)
 * [16 years, 9 months ago](https://wordpress.org/support/topic/css-help-8/#post-1181285)
 * `.topPost .single p {font-size:11px}`
 * Here you declare .single as a decendent of .topPost, which it is not.
 * Just
 * `.single p {font-size:11px}`
 * .something declares a class (which is allowed to be more often on a single page)
   opposed to #something, which is an id. An id can only be once on a single page.
 * Peter

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

The topic ‘CSS help’ is closed to new replies.

 * 3 replies
 * 3 participants
 * Last reply from: [Peter Boosten](https://wordpress.org/support/users/pboosten/)
 * Last activity: [16 years, 9 months ago](https://wordpress.org/support/topic/css-help-8/#post-1181285)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
