HTML-Adress-Tag
Die
Syntax
Die Syntax der
Tag wird wie unten gezeigt geschrieben:<html> <body> <address> Contact Information:<br> www.mycompany.com<br> #12345, Main Street<br> Name of City, Name of State </address> </body> </html>
Attribute
Hier sind die folgenden Attribute aufgeführt
1. Globale Attribute
Globale Attribute beziehen sich auf Attribute, die in jedem HTML-Element verwendet werden. Solche Attribute sind in allen HTML-Elementen verbreitet.
- accesskey: Definiert die Tastenkombination zum Aktivieren des Elements.
- Klasse: Gibt die Klassennamen für ein Element an.
- contenteditable: Wird verwendet, um anzugeben, ob ein Element bearbeitet werden kann oder nicht.
- dir: Wird verwendet, um die Textrichtung eines Elements zu definieren.
- Dragable: Es definiert, wie das Element auf der Seite gezogen werden kann.
- Dropzone: Wird verwendet, um anzugeben, ob Daten kopiert, verschoben oder verknüpft werden können, wenn sie verbunden sind.
- id: Definiert die spezifische ID für das Element.
- lang: Es definiert die Sprache für den Inhalt des Elements.
- Stil: Stellt den CSS-Stil für das Element bereit.
- tabindex: Wird verwendet, um die Tab-Reihenfolge für das Element zu definieren.
- Titel: Wird verwendet, um zusätzliche Informationen für das Element bereitzustellen.
- übersetzen: Gibt an, ob der Inhalt des Elements übersetzt werden kann oder nicht.
- Rechtschreibprüfung: Definiert die Rechtschreibprüfung für den Inhalt eines Elements.
- Daten: Wird zum Austausch privater Daten zwischen HTML- und DOM-Darstellung verwendet.
- versteckt: Dieses Attribut wird verwendet, wenn die Elemente ausgeblendet werden müssen
2. Ereignisattribute
Ein Ereignis tritt immer dann ein, wenn ein Browser auf den Eingriff eines bestimmten Benutzers reagiert. Wenn ein Benutzer mit der Maus klickt, ein Dokument oder ein Bild hochlädt, ein Video abspielt oder eine andere Aktivität auf einer Webseite ausführt.
3. Windows-Ereignisattribute
Fensterereignisattribute werden verwendet, wenn Fensterobjekte initiiert werden.
- onafterprint: Wird verwendet, wenn das Dokument gedruckt werden muss.
- onbeforeprint: Wird ausgeführt, bevor das Dokument gedruckt werden muss.
- onbeforeload: Wird verwendet, wenn das Dokument entladen wird.
- onblur: Dieses Attribut wird definiert, wenn kein Fokus vom Fenster vorhanden ist.
- onerror: Wird definiert, wenn beim Herunterladen des Dokuments ein Fehler auftritt.
- onload: Wird angegeben, wenn Webseiteninhalte geladen werden.
- onmessage: Wird verwendet, wenn eine Nachricht einen Grund hat.
- onoffline: Dieses Attribut wird verwendet, wenn der Browser im Offline-Modus arbeitet.
- ononline: Dieses Attribut wird verwendet, wenn der Browser im Online-Modus funktioniert.
- onpagehide: Wird angegeben, wenn der Benutzer die Webseite verlässt.
- onpageshow: Wird angegeben, wenn der Benutzer zur Webseite navigiert.
- onpopstate: Dieses Attribut wird verwendet, wenn es eine Änderung im Fensterverlauf gibt.
- onredo: Wird verwendet, wenn es auf einer Seite eine Redo-Option gibt.
- onresize: Wird angegeben, wenn der Benutzer die Größe des Fensters ändert.
- onstorage: Wird definiert, wenn es ein Update im Webspeicher gibt.
- onundo: Wird verwendet, wenn eine Rückgängig-Option vorhanden ist, die abgebrochen werden kann.
- onunload: Wird angegeben, wenn der Webseiteninhalt entladen wird.
4. Formularereignisattribute
Ein Ereignis, das innerhalb eines Formulars stattfinden kann, wird als Ereignis im Prozess betrachtet. Die Formularereignisse treten auf, wenn ein Benutzer ein Formular öffnet oder schließt, zwischen Formularen wechselt oder ein Formular mit Daten bearbeitet.
- onblur: This attribute will be defined when there is no focus on the form element.
- onchange: It is defined when there is a change in the value of an element.
- oncontextmenu: It is used when the user wants to see the context menu.
- onfocus: It is used when an element gets a focus.
- oninput: It is used when an element gets input from the user.
- oninvalid: It is specified when there is an invalid element on a page.
- onreset: This attribute will be used when a user wants to reset the form.
- onsearch: It is defined when the user searches for some information in the search field.
- onselect: It is used when the user selects the text in an element.
- onsubmit: It is used when the user submits the form.
Examples of implementing HTML address Tag
Here are the following examples mention below
Example #1
<!doctype html> <html> <head> <meta charset="UTF-8"> <title> HTML Address Tag </title> </head> <body> <article> <h2>This is Heading Title</h2> <p>Information about article will be written here...</p> </article> <footer> <address> Contact Address:<br> mycompany.com<br> #987 5th Main, 10th Cross<br> XYZ road<br> New Delhi, India </address> </footer> </body> </html>
Output:
- Save the above code in a file with a .html extension
- Run the html file in a browser, and you would get the output as shown in the below image
Example #2 – Color property
Code:
<!doctype html> <html> <head> <meta charset="UTF-8"> <title> HTML Address Tag </title> <style> .color_prop { color: #1c87c9; } </style> </head> <body> <article> <h2>This is Heading Title</h2> <p>Information about article will be written here...</p> </article> <footer> <address> <p class="color_prop">Contact Address:</p> mycompany.com<br> #987 5th Main, 10th Cross<br> XYZ road<br> New Delhi, India </address> </footer> </body> </html>
Output:
Run the above file in a browser, and you would get the output as shown in the below image:
Example #3 – Background Color Property
Code:
<!doctype html> <html> <head> <meta charset="UTF-8"> <title> HTML Address Tag </title> <style> .color_prop { background-color: #1c87c9; } </style> </head> <body> <article> <h2>This is Heading Title</h2> <p>Information about article will be written here...</p> </article> <footer> <address> <div class="color_prop">Contact Address:<br> mycompany.com<br> #987 5th Main, 10th Cross<br> XYZ road<br> New Delhi, India </div> </address> </footer> </body> </html>
Output:
Run the above file in a browser, and you would get the output as shown in the below image:
Example #4 – Text Decoration
Code:
<!doctype html> <html> <head> <meta charset="UTF-8"> <title> HTML Address Tag </title> <style> .style1 { text-decoration: underline; } .style2 { text-decoration: italic; } </style> </head> <body> <article> <h2>This is Heading Title</h2> <p>Information about article will be written here...</p> </article> <footer> <address> <p class="style1">Contact Address:</p> <p class="style2">mycompany.com</p> #987 5th Main, 10th Cross<br> XYZ road<br> New Delhi, India </div> </address> </footer> </body> </html>
Output:
Run the above file in a browser, and you would get the output as shown in the below image:
Example #5 – CSS Fonts
Code:
<!doctype html> <html> <head> <meta charset="UTF-8"> <title> HTML Address Tag </title> <style> .style1 { font-family:"Lucida Sans Unicode", "Lucida Grande", sans-serif; } .style2 { font-weight: bolder; } </style> </head> <body> <article> <h2>This is Heading Title</h2> <p>Information about article will be written here...</p> </article> <footer> <address> <p class="style1">Contact Address:</p> <p class="style2">mycompany.com</p> #987 5th Main, 10th Cross<br> XYZ road<br> New Delhi, India </div> </address> </footer> </body> </html>
Output:
Run the above file in a browser, and you would get the output as shown in the below image:
Example #6 – Text Shadow
Code:
<!doctype html> <html> <head> <meta charset="UTF-8"> <title> HTML Address Tag </title> <style> .style1 { text-shadow: 2px 2px #1c87c9; } </style> </head> <body> <article> <h2>This is Heading Title</h2> <p>Information about article will be written here...</p> </article> <footer> <address> <p class="style1">Contact Address:</p> mycompany.com<br> #987 5th Main, 10th Cross<br> XYZ road<br> New Delhi, India </div> </address> </footer> </body> </html>
Output:
Run the above file in a browser, and you would get the output as shown in the below image:
Example #7 – Line Height
Code:
<!doctype html> <html> <head> <meta charset="UTF-8"> <title> HTML Address Tag </title> <style> .color_prop { line-height: 2.0; } </style> </head> <body> <article> <h2>This is Heading Title</h2> <p>Information about article will be written here...</p> </article> <footer> <address> <div class="color_prop">Contact Address:<br> mycompany.com<br> #987 5th Main, 10th Cross<br> XYZ road<br> New Delhi, India </div> </address> </footer> </body> </html>
Output:
Run the above file in a browser, and you would get the output as shown in the below image:
Conclusion
So far, we have studied how to address tag will be used when an owner wants to specify the address information. In order to quickly contact the author via email, this feature is often combined with the HTML mailto property. The address tag will usually be included in the section < footer> section.
Das obige ist der detaillierte Inhalt vonHTML-Adress-Tag. Für weitere Informationen folgen Sie bitte anderen verwandten Artikeln auf der PHP chinesischen Website!

Heiße KI -Werkzeuge

Undresser.AI Undress
KI-gestützte App zum Erstellen realistischer Aktfotos

AI Clothes Remover
Online-KI-Tool zum Entfernen von Kleidung aus Fotos.

Undress AI Tool
Ausziehbilder kostenlos

Clothoff.io
KI-Kleiderentferner

Video Face Swap
Tauschen Sie Gesichter in jedem Video mühelos mit unserem völlig kostenlosen KI-Gesichtstausch-Tool aus!

Heißer Artikel

Heiße Werkzeuge

Notepad++7.3.1
Einfach zu bedienender und kostenloser Code-Editor

SublimeText3 chinesische Version
Chinesische Version, sehr einfach zu bedienen

Senden Sie Studio 13.0.1
Leistungsstarke integrierte PHP-Entwicklungsumgebung

Dreamweaver CS6
Visuelle Webentwicklungstools

SublimeText3 Mac-Version
Codebearbeitungssoftware auf Gottesniveau (SublimeText3)

Heiße Themen











Anleitung zum Tabellenrahmen in HTML. Hier besprechen wir verschiedene Möglichkeiten zum Definieren von Tabellenrändern anhand von Beispielen für den Tabellenrand in HTML.

Dies ist eine Anleitung für verschachtelte Tabellen in HTML. Hier diskutieren wir anhand der entsprechenden Beispiele, wie man eine Tabelle innerhalb der Tabelle erstellt.

Anleitung zum HTML-Rand links. Hier besprechen wir einen kurzen Überblick über HTML margin-left und seine Beispiele sowie seine Code-Implementierung.

Leitfaden zum HTML-Tabellenlayout. Hier besprechen wir die Werte des HTML-Tabellenlayouts zusammen mit den Beispielen und Ausgaben im Detail.

Leitfaden für HTML-Eingabeplatzhalter. Hier besprechen wir die Beispiele für HTML-Eingabeplatzhalter zusammen mit den Codes und Ausgaben.

Dieses Tutorial zeigt, wie XML -Dokumente mit PHP effizient verarbeitet werden. XML (Extensible Markup-Sprache) ist eine vielseitige textbasierte Markup-Sprache, die sowohl für die Lesbarkeit des Menschen als auch für die Analyse von Maschinen entwickelt wurde. Es wird üblicherweise für die Datenspeicherung ein verwendet und wird häufig verwendet

Leitfaden zur HTML-geordneten Liste. Hier besprechen wir auch die Einführung von HTML-geordneten Listen und Typen sowie deren Beispiele

Anleitung zum HTML-OnClick-Button. Hier diskutieren wir deren Einführung, Funktionsweise, Beispiele und Onclick-Events in verschiedenen Veranstaltungen.
