Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS Classes on header, section, article, footer ?

  • This topic is empty.
Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #45240
    Rugg
    Participant

    Hello,

    I came across the following article which suggests the _header, section, article, footer_ tags in html5 should not be used for styling content… therefore classes/ ids should not be used to target css. The article is dated 2011, so Im curious if the suggested practice has changed at all. I continue to see other sites using classes and ids on the mentioned tags.

    If anyone as any ideas or can suggest an updated article stating otherwise… I would much appreciate it. Thank you.

    Article: http://html5doctor.com/avoiding-common-html5-mistakes/

    #136804
    unasAquila
    Participant

    I would agree they are not for styling content in that they are implemented for making a more semantic markup and should first and foremost be used in this way.

    #136806
    Kitty Giraudel
    Participant

    You don’t style div, span, h1, and p tags directly. Thus, you shouldn’t style header, article, section and footer directly.

    #136819
    unasAquila
    Participant

    The article is talking about “style” as in the markup not styling ie

    Generic header

    Something else generic

    is more semantic than say

    Generic header

    Something else generic

    but that is not to say that the second is wrong

    or as to the

    If this this the wrapper for this section then there is no problem using a class for styling as long as the section is being used correctly.

    The issue is people doing this

    Blog header

    some blog stuff…

    when all they need is

    Blog header

    some blog stuff…

    #136825
    unasAquila
    Participant

    off course, it only when people over extend there use to layout there site that it becomes “styling elements” rather that “structural elements” as they were intended

Viewing 5 posts - 1 through 5 (of 5 total)
  • The forum ‘CSS’ is closed to new topics and replies.