Grow your CSS skills. Land your dream job.

Span Problem – Font Change on 1 Line

  • # April 14, 2009 at 5:12 pm

    Please help….
    I have placed the <h5> with a portion in the middle meant to go blue caps. But instead of achieving everything I read that is supposed to happen – the word BLUE jumps to the next line AND "then back to black" jumps to a third line.

    My code is below…..
    UGH — can anyone point me in the right direction? It is all meant to be on one line.

    Thanks, Jennifer

    Code:
    This text is black and blue then back to black.

    /**************** Black Intro ****************/
    h5
    {
    background-color: transparent;
    color: #000000;
    font-family: “Trebuchet MS”, Arial, Helvetica, sans-serif;
    font-size: 1.3em;
    border-style: hidden;
    font-style: italic;
    font-weight: normal;
    text-align: left;
    line-height: 25px;
    }

    /**************** Home Emphazied Blue Text ****************/
    span.homeblue
    { color: #00468b;
    font-size: 1.3em;
    text-transform: uppercase;
    font-weight: bolder;
    font-style: italic;
    }

    # April 14, 2009 at 5:14 pm

    Here is a screen capture of what I am getting with the above code

    # April 14, 2009 at 5:26 pm

    That should be fine the way it is. I’m assuming its the other properties in your stylesheet that is causing your problem. I would look for some thing like a display:block; on a span in one of your heading properties.

    I would also learn short hands: http://www.smashingmagazine.com/2008/08 … -css-code/

    # April 15, 2009 at 2:43 pm

    I did have another span with display: block;
    Thanks! New to CSS and I wouldn’t have known to look for that and that the two codes were fighting.

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.

*May or may not contain any actual "CSS" or "Tricks".