#1
  1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Sep 2010
    Posts
    18
    Rep Power
    0

    Aligning Headings?


    I'm having trouble aligning headings in CSS.

    I've tried creating a class like this -

    Code:
    .rightalign {
       text-align:right;
    }
    and applying it like this -

    Code:
    <h1> <span class="rightalign" /> Heading </span> </h1>
    but it doesn't work, any help?

    Thank you.
  2. #2
  3. Backwards Moderator
    Devshed Supreme Being (6500+ posts)

    Join Date
    Mar 2007
    Location
    Washington, USA
    Posts
    16,926
    Rep Power
    9646
    1. Won't work with a span.
    2. Invalid HTML anyways.
    Code:
    <h1 class="rightalign">Heading</h1>
  4. #3
  5. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Sep 2010
    Posts
    18
    Rep Power
    0
    Originally Posted by requinix
    1. Won't work with a span.
    2. Invalid HTML anyways.
    Code:
    <h1 class="rightalign">Heading</h1>

    I'm so stupid, thank you!

IMN logo majestic logo threadwatch logo seochat tools logo