css validation error for "meta"

Discussion in 'CSS' started by driven, Aug 29, 2006.

  1. #1
    I was trying to validate a CSS stylesheet and I got this error;

    The element type "meta" must be terminated by the matching end-tag "</meta>".​

    What does that mean? I tried to put "</meta> at the end of the line that it wanted me to but that doesn't seem to work.

    Thoughts?
     
    driven, Aug 29, 2006 IP
  2. Gordaen

    Gordaen Peon

    Messages:
    277
    Likes Received:
    12
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Try changing your meta tags to look like this:

    <meta name="keywords" content="fricken awesome webpage" />
     
    Gordaen, Aug 30, 2006 IP
  3. driven

    driven Well-Known Member

    Messages:
    400
    Likes Received:
    14
    Best Answers:
    0
    Trophy Points:
    138
    #3
    Really? does the validator actually look for stuff like that?
     
    driven, Aug 30, 2006 IP
  4. kk5st

    kk5st Prominent Member

    Messages:
    3,497
    Likes Received:
    376
    Best Answers:
    29
    Trophy Points:
    335
    #4
    That's what a validator does, it checks your (x)html syntax.

    cheers,

    gary
     
    kk5st, Aug 30, 2006 IP
  5. Gordaen

    Gordaen Peon

    Messages:
    277
    Likes Received:
    12
    Best Answers:
    0
    Trophy Points:
    0
    #5
    That's one of the many things it looks for.

    I just noticed you said meta tags in your CSS file. Is that what you meant to say? (maybe you meant that the meta tag in your html file that includes the css file had the problem?)

    For XHTML, tags have to be closed. That means you use <p></p> rather than just <p> as an example. Some tags don't contain anything, so they are self-closing. For instance, a line break: <br />

    For HTML4, you don't do this. If you are validating an (x)html page, your DOCTYPE tells the validator what type of page it is.
     
    Gordaen, Aug 31, 2006 IP
  6. driven

    driven Well-Known Member

    Messages:
    400
    Likes Received:
    14
    Best Answers:
    0
    Trophy Points:
    138
    #6
    I meant to say that my css style is embedded within my html page. I'm just testing this layout so that is why it's embedded. does that help?
     
    driven, Aug 31, 2006 IP
  7. Gordaen

    Gordaen Peon

    Messages:
    277
    Likes Received:
    12
    Best Answers:
    0
    Trophy Points:
    0
    #7
    Yeah, that makes more sense :)

    You may be interested in reading the W3 Schools pages about XHTML.

    If you do the majority of your testing in Firefox, there are a lot of extensions that are helpful too. Check out the HTML Validator and the Web Developer ones for starters.
     
    Gordaen, Aug 31, 2006 IP