HTML Element: address

The HTML <address> element represents the contact information for a person or organization associated with the document. It shouldn’t be used for arbitrary postal addresses.

Specifically, <address> is reserved for contact details connected with the nearest <article> or <body> ancestor, or the nearest <blockquote>, <figure>, or <td> ancestor in that order.

Syntax

The <address> element is an inline element and is written like this:

1
<address>
2

3
<!-- Contact information goes here -->
4

5
</address>

Example

Here’s an example of how you can use the <address> element to provide contact information for the author of an article:

1
<article>
2
  <header>
3
    <h1>My Awesome Article</h1>
4
    <address>
5
      Written by Andy L.<br>
6
      Email: andy@web-crunch.com<br>
7
      Twitter: <ahref="https://twitter.com/webcrunchblog">@webcrunchblog</a>
8
    </address>
9
  </header>
10
  <p>Lorem ipsum dolor sit amet...</p>
11
</article>

Result

Attributes

The <address> element has no specific attributes. However, it can be styled using global attributes, such as class or id.

Content

The content of the <address> element typically consists of contact information for the author or owner of a document, such as a name, email address, physical address, or phone number.

Did You Know?

  • The <address> element was introduced when the HTML 3 spec was drafted in 1995.
  • The <address> element is often combined with the <footer> element to provide additional information about the author or owner of a document.

“The address element is not appropriate for all postal and e-mail addresses; it should be reserved for providing such information about the contact people for the document.” — W3C HTML5 specification

Learn More


This content originally appeared on Envato Tuts+ Tutorials and was authored by Andy Leverenz

The HTML <address> element represents the contact information for a person or organization associated with the document. It shouldn’t be used for arbitrary postal addresses.

Specifically, <address> is reserved for contact details connected with the nearest <article> or <body> ancestor, or the nearest <blockquote>, <figure>, or <td> ancestor in that order.

Syntax

The <address> element is an inline element and is written like this:

1
<address>
2
3
<!-- Contact information goes here -->
4
5
</address>

Example

Here’s an example of how you can use the <address> element to provide contact information for the author of an article:

1
<article>
2
  <header>
3
    <h1>My Awesome Article</h1>
4
    <address>
5
      Written by Andy L.<br>
6
      Email: andy@web-crunch.com<br>
7
      Twitter: <ahref="https://twitter.com/webcrunchblog">@webcrunchblog</a>
8
    </address>
9
  </header>
10
  <p>Lorem ipsum dolor sit amet...</p>
11
</article>

Result

Attributes

The <address> element has no specific attributes. However, it can be styled using global attributes, such as class or id.

Content

The content of the <address> element typically consists of contact information for the author or owner of a document, such as a name, email address, physical address, or phone number.

Did You Know?

  • The <address> element was introduced when the HTML 3 spec was drafted in 1995.
  • The <address> element is often combined with the <footer> element to provide additional information about the author or owner of a document.

“The address element is not appropriate for all postal and e-mail addresses; it should be reserved for providing such information about the contact people for the document.” — W3C HTML5 specification

Learn More


This content originally appeared on Envato Tuts+ Tutorials and was authored by Andy Leverenz


Print Share Comment Cite Upload Translate Updates
APA

Andy Leverenz | Sciencx (2023-04-20T07:22:51+00:00) HTML Element: address. Retrieved from https://www.scien.cx/2023/04/20/html-element-address/

MLA
" » HTML Element: address." Andy Leverenz | Sciencx - Thursday April 20, 2023, https://www.scien.cx/2023/04/20/html-element-address/
HARVARD
Andy Leverenz | Sciencx Thursday April 20, 2023 » HTML Element: address., viewed ,<https://www.scien.cx/2023/04/20/html-element-address/>
VANCOUVER
Andy Leverenz | Sciencx - » HTML Element: address. [Internet]. [Accessed ]. Available from: https://www.scien.cx/2023/04/20/html-element-address/
CHICAGO
" » HTML Element: address." Andy Leverenz | Sciencx - Accessed . https://www.scien.cx/2023/04/20/html-element-address/
IEEE
" » HTML Element: address." Andy Leverenz | Sciencx [Online]. Available: https://www.scien.cx/2023/04/20/html-element-address/. [Accessed: ]
rf:citation
» HTML Element: address | Andy Leverenz | Sciencx | https://www.scien.cx/2023/04/20/html-element-address/ |

Please log in to upload a file.




There are no updates yet.
Click the Upload button above to add an update.

You must be logged in to translate posts. Please log in or register.