What does HTML define on a webpage?
HTML describes the structure and meaning of web content; CSS controls presentation, and JavaScript can add behavior.
Study 2 HTML Structure and Semantics with 12 free online flashcards. Review key terms, definitions, and concepts with this interactive flashcard deck.
What does HTML define on a webpage?
HTML describes the structure and meaning of web content; CSS controls presentation, and JavaScript can add behavior.
What makes HTML semantic?
Semantic HTML uses elements for their intended purposes, giving content meaningful structure and often useful browser and accessibility behavior by default.
What belongs in the head element?
The head contains document information such as character encoding and the title shown in the browser tab.
Why set the page's lang attribute?
The lang attribute identifies the page's language, helping assistive technology pronounce its content appropriately.
What does the body element contain?
The body contains the webpage's content.
What do header, nav, main, and footer describe?
Elements such as header, nav, main, and footer identify common regions of a page.
How do article, section, and div differ?
An article is for self-contained content; a section groups related content, usually under a heading. Use a div when no more meaningful element fits.
How should heading levels organize a page?
Use heading levels to show content hierarchy: a main topic commonly uses h1, major sections h2, and subsections h3. Headings also let readers, including screen-reader users, navigate by section.
What creates a link in HTML?
An anchor element with an href attribute creates a link to a destination.
What makes link text descriptive?
Link text should make the destination or action understandable, even when read outside its surrounding paragraph.
How does a link target a location on the same page?
A link to a location on the same page uses a fragment identifier that matches the destination element's id.
When should you use a link rather than a button?
Links navigate to destinations; buttons perform actions. Choose the element that matches the task to get appropriate built-in browser behavior.