Results 1 to 3 of 3

Thread: 2 different fonts on same line

  1. #1
    Join Date
    May 2009
    Location
    Greensboro, GA
    Posts
    106
    Thanks
    5
    Thanked 0 Times in 0 Posts

    Default 2 different fonts on same line

    I've been cleaning up my code and validating my pages in xhtml and run across a problem. how do I code the following line (appears on 1 line only) using style:

    Mission Statement:Have fun

    And how do I code this 1 line:

    Mission Statement:Have Fun

    Thanks for any help
    Last edited by mcolton; 08-06-2009 at 03:56 PM.

  2. #2
    Join Date
    Apr 2009
    Location
    Cognac, France
    Posts
    400
    Thanks
    2
    Thanked 57 Times in 57 Posts

    Default

    Is this the type of thing you mean when you say you want to get that effect using style.

    HTML Code:
    <style>
    
    .large_font{
    	font-size: 18pt;
    }
    
    .small_font{
    	font-size: 12pt;
      }
    
    </style>
    </head>
    
    <body>
    
    <span class="large_font">
    Mission Statement: 
    </span>
    <span class="small_font">
    Have fun
    </span>
    To get either class in italics just add font-style:italic; into the relevant class in the style section

  3. #3
    Join Date
    May 2009
    Location
    Greensboro, GA
    Posts
    106
    Thanks
    5
    Thanked 0 Times in 0 Posts

    Default

    Thanks. I knew it was easy I just couldn't get it to work

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •