HTML Element: address

Date:


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





Source link

About Author

Previous articleHTML Element: article
Next articleHTML Element: abbr

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Share post:

Subscribe

spot_imgspot_img

Popular

More like this
Related

UIBundle: A One-Stop Shop for Design Resources, Freebies, & Tips

Every designer has a favorite website where...

Collective #784

State of HTML 2023 * Nue * The...

How to Create CSS Ribbon Shapes with a Single Element — SitePoint

In this article, I’ll show you how to...

Market Test: Get Real Human Feedback on Your Designs

Conjointly’s Market Test is a suite of...