I am brand new to html, so struggling a bit with new html5 elements.
I have 2 scenarios where I can’t decide if I should be using article or section.
Scenario 1:
I have a home page, which contains lots of different sections (by this I don’t necessarily mean html sections). To give an example, 1 part of the home page contains reasons to use my company/website – it also has a header.
This is displayed on the home page, but then also on many other pages in the sidebar. If I understand correctly this would fall under article, but I’m not entirely sure.
Scenario 2:
I have a frequently asked questions page. Each question has an answer, and a number of questions may be grouped under a specific topic.
So, is each topic a section, and each question/answer an article? Also is the question a header to the article?
Any help and advice would be very much appreciated.
For the FAQ, I would suggest to use
sectionfor each topic (including a headline) a description listdlwith adtfor each question and one or more answers, each wrapped in it’s owndd. You could also omit thesections and use nested description lists.The use of
articledoes not make sense here, as of the spec. Think of thearticleelement for use cases like blog articles.I don’t understand your first scenario.