How to organize titles

Asked

Viewed 94 times

1

How to organize titles in an html document? Ex: I have 2 Section, 3 div’s, one Nav, 1 aside and 3 article. So should I sort titles and subtitles for each element or for the whole page? That is, each element or section will have an H1 or my orientation should be relative to the general page?

<h1>PRINCIPAL</h1>
<h2>ASSUNTO 1</h2>
<h3>SUBTITULO DO H2</h3>
<h2>ASSUNTO 2</h2>
<h3>SUBTITULO DO H2</h3>
<h2>ASSUNTO 3</h2>
<h3>SUBTITULO DO H2</h3>
</section>
<section class="lado esquerdo"> <nav></nav> <aside>outros elementos e assuntos <article>outros elementos e assuntos </section>
</section>
  • 4

    Could you please put your HTML content here?

  • in general the focus is the content...

  • <Section class="all"> <Section class="right side"> <H1>MAIN</H1> <H2>SUBJECT 1</H2> <H3>SUBTTULE DO H2</H3> <H2>SUBJECT 2</H2> <H3>SUBTITULO DO H2</H3> <H2>TOPIC 3</H2> <H3>SUBTITULO DO H2</H3> </Section> <Section class="left side"> <Nav></Nav> <aside>other elements and subjects <article>other elements and subjects </Section> </Section> would be something like this.

  • As far as I know, it only has 1 H1 element per page. http://www.maujor.com/w3ctuto/qatips/useh1.html

  • Thanks, that’s what I wanted to know. It helped a lot.

  • Welcome to Stack Overflow in English! Welcome to [en.so]. Your question is very broad, the standard of the community are objective questions and have at least one correct answer, as can be seen in the [help] link [Ask]. I do not understand very well what you refer to with "organize titles", could explain better. And while you’re at it, take a [tour] tour and then you can [Dit] your question so we can help you.

Show 1 more comment

2 answers

3

I didn’t quite understand your question, but I’ll try to answer what I understood.

The order of the headings H1, H2, H3,... "does not interfere" on the page. This will according to your layout and how you prefer. See this example with several <h1> on the page:

<h1>PRINCIPAL</h1>
<h2>ASSUNTO 1</h2>
<h3>SUBTITULO DO H2</h3>
<h1>PRINCIPAL 2</h1>
<h2>ASSUNTO 2</h2>
<h3>SUBTITULO DO H2</h3>
<h1>PRINCIPAL 2</h1>
<h2>ASSUNTO 3</h2>
<h3>SUBTITULO DO H2</h3>
</section>
<section class="lado esquerdo"> <nav></nav> <aside>outros elementos e assuntos <article>outros elementos e assuntos </section>
</section>

Now, note that if your concern is SEO, the approach changes. For this, several factors are taken into account, including the <h1>. For this, some factors should be taken into account, such as:

1 - H1 with the keyword of the main idea

2 - H2 with the keywords of the main idea elements

3 - H3 to further divide the elements and facilitate understanding and visualization of people and robots.

Note a practical example of their use:

Suppose you want to make a website selling cars called cars.com.

<h1>

The largest list of new, semi-new and used cars on the internet

Note in the H1 example above that some possible Keywords of the site have been used and the text is written in a way that the user can understand.

<h2>

For sale Carros da Marca FIAT

Already in the text of H2 we have something more specific, ie it is a subsection of H1, and again we put some site Keywords in H2, this helps a lot the search engines and the user to find what they need on the site

<h3>

For sale Carros Fiat Punto

Just like in H2, H3 has to be a top H# add-on. And this rule has to be followed up to the H6 tag.

Note: You’ll find more on the subject if you use the keyword Heading Elements or Heading Tags.

Sources:

0

Follow what the W3C says.

Source W3C => http://www.maujor.com/w3ctuto/qatips/useh1.html

Use H1 for first-level headers

H1 is the HTML element used for first-level headers in a page:

If the document is unique in its subject, for example: Things to do to see and to do in Geneva, the top level header probably equal the title of the document. If the document is a of a collection on a subject, for example: a page on dogs being part of a collection of pet pages, the first level header may be a specific text referring to to the subject; only

Dogs

while the title may be any generic text related to the subject: Dogs - Guide for animals estimation. Unlike the title, this element, the , can contain links, emphasis or other HTML Phrase Elements (HTML element for phrases).

The default font size ("default") adopted by some browsers for , unfortunately has led some designers to adopt the . To tools that use the page structure for your performance, such as Amaya’s table of Contents view (NT: Amaya tool that relates the contents of a page) practice (use in place of ) is harmful. Consider the use of Cascade Style Sheets , which were developed to express the font sizes preferred by designers for elements such as H1 and H2.

  • 1

    You are not confusing <h1> with <title> nay?

  • 1

    Complain with W3C @Randrade

  • I’m not saying that. I’m just saying that H1 is for headers, as the text itself says. Now 1 per page?

  • Better? @Randrade

  • Now it’s gotten better. The very page of W3 has an example with 2 <h1>. The element <title> fits 1 per page.

  • 1

    @Randrade Got it, thanks.

Show 1 more comment

Browser other questions tagged

You are not signed in. Login or sign up in order to post.