Elementi di Testo in HTML

Elementi di Testo in HTML

Capitolo 3 del tutorial, dedicato agli elementi di testo in HTML.

3. Elementi di Testo in HTML

Il testo è il cuore di ogni pagina web.
In HTML possiamo formattarlo e organizzarlo usando diversi elementi, ognuno con un significato e una funzione precisa.

3.1 Titoli (<h1><h6>)

I titoli servono a dare gerarchia e struttura ai contenuti.

  • <h1> è il titolo più importante (usalo una sola volta per pagina).

  • <h6> è il meno importante e il più piccolo.

Esempio:

<h1>Benvenuto nel mio sito</h1>
<h2>Chi sono</h2>
<h3>La mia storia</h3>

Consiglio SEO: I motori di ricerca usano i titoli per capire l’argomento della pagina.

3.2 Paragrafi (<p>)

Ogni paragrafo si scrive tra i tag <p> e </p>.

<p>Questo è un paragrafo di testo.</p>
<p>Questo è un altro paragrafo.</p>

3.3 Formattazione del testo

HTML offre tag per dare enfasi o modificare l’aspetto del testo:

Tag Significato Esempio
<b> Grassetto (solo stile) <b>Importante</b>
<strong> Grassetto + importanza semantica <strong>Molto importante</strong>
<i> Corsivo (solo stile) <i>Parola straniera</i>
<em> Enfasi semantica <em>Attenzione</em>
<u> Sottolineato <u>Testo sottolineato</u>

3.4 Liste

Le liste permettono di organizzare informazioni in punti.

Lista non ordinata (<ul>)

<ul>
    <li>Pane</li>
    <li>Latte</li>
    <li>Uova</li>
</ul>

Lista ordinata (<ol>)

<ol>
    <li>Accendere il computer</li>
    <li>Aprire il browser</li>
    <li>Visitare un sito web</li>
</ol>

3.5 Citazioni e abbreviazioni

  • Citazione breve: <q>

  • Citazione lunga: <blockquote>

  • Abbreviazioni: <abbr>

Esempio:

<p>Come disse <q>Leonardo da Vinci</q>, la semplicità è la massima sofisticazione.</p>

<blockquote>
    Questo è un testo citato da un'altra fonte.
</blockquote>

<p><abbr title="HyperText Markup Language">HTML</abbr> è il linguaggio del web.</p>

English version

Chapter 3 of the tutorial, dedicated to text elements in HTML.

3. Text Elements in HTML

Text is the heart of every web page.

In HTML, we can format and organize it using different elements, each with a specific meaning and function.


3.1 Headings (<h1> … <h6>)

Headings provide hierarchy and structure to content.

  • <h1> is the most important heading (use it only once per page).
  • <h6> is the least important and the smallest.


Example:

<h1>Welcome to my site</h1>

<h2>About me</h2>

<h3>My story</h3>

SEO tip: Search engines use headings to understand the topic of the page.


3.2 Paragraphs (<p>)

Each paragraph is written between the <p> and </p> tags.


<p>This is a paragraph of text.</p>

<p>This is another paragraph.</p>


3.3 Text Formatting

HTML offers tags to add emphasis or change the appearance of text:

  • <b>: Bold (style only), ex. <b>Important</b>
  • <strong>: Bold + semantic importance, ex. <strong>Very important</strong>
  • <i>: Italic (style only), ex. <i>Foreign word</i>
  • <em>: Semantic emphasis, ex. <em>Attention</em>
  • <u>: Underline, ex. <u>Underlined text</u>

3.4 Lists

Lists allow you to organize information into bullet points.

Unordered List (<ul>)

<ul>

<li>Bread</li>

<li>Milk</li>

<li>Eggs</li>

</ul>

Ordered List (<ol>)

<ol>

<li>Turn on the computer</li>

<li>Open the browser</li>

<li>Visit a website</li>

</ol>

3.5 Quotations and Abbreviations

  • Short quote: <q>
  • Long quote: <blockquote>
  • Abbreviations: <abbr>

Example:

<p>As <q>Leonardo da Vinci</q> said, simplicity is the ultimate sophistication.</p>

<blockquote>

This is a text quoted from another source.

</blockquote>


<p><abbr title="HyperText Markup Language">HTML</abbr> is the language of the web.</p>

Puoi seguire anche il mio canale YouTube https://www.youtube.com/channel/UCoOgys_fRjBrHmx2psNALow/ con tanti video interessanti


I consigli che offriamo sono di natura generale. Non sono consigli legali o professionali. Quello che può funzionare per una persona potrebbe non essere adatto a un’altra, e dipende da molte variabili.
Per supportare e far crescere il canale in modo semplice, rapido e gratuito, potete fare acquisti su amazon usando il mio link di affiliazione.
Questo implica che io prenda una commissione ogni volta che qualcuno faccia un qualsiasi acquisto utilizzando il mio link di affiliazione https://amzn.to/4cgJ3Ls

Commenti