Support » Themes and Templates » Internal CSS in WordPress 1.5 beta pages

  • I forgot what build I’m using. I’ll just hope it’s not necessary. -.-

    I’m attempting to add an internal CSS to my pages for formatting. However, only the first targetted tag on the page is being formatted. Below is the code I’m using (the CSS is placeholder code at the moment, until I get it working).

    <style type="text/CSS">
    {font-size: 10%;
    padding-top: 15px;}

    {font-size: 200%;
    padding-top: 100px;}

    <span class="links_category">Category</span>
    <span class="links_title"><a href="#">Title</a></span>

    Ideally, the CSS would apply to both, but it only applies to the first one. Any suggestions would be appreciated. My website is and the page in question the Links page.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Spans only travel for the line they are on. Any line break and they are toast. They also don’t do well inside of each other. Try changing this to DIV instead of SPAN and see what happens.

    10% is really tiny, so you might want to make that a little larger, though you do say that this is the one that is working. Ah, check the CSS for your anchors (a) like those found in:

    <div id="header"><a href="nothing.html">Nothing Title</a></header>

    Which you might find listed as:

    #header a {some style stuff here]

    This might be influencing the second style reference.

    I eventually solved this. It turns out that I had an option selected in the configuration to automatically make all posts (pages count as posts, it seems) valid XHTML. That option for some reason refused to recognize certain valid XHTML tags, thus destroying the CSS scheme. I fixed it by deselecting that option.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Internal CSS in WordPress 1.5 beta pages’ is closed to new replies.