HTML Anchor <A> Tag Attributes

What are links in HTML - HTML Links - Hyperlink

How to create links to different sections of same page - connecting sections of same page

In this tutorial, we tutorial you will learn about different attributes of anchor <a> tag.

Hyperlink Attributes


title Defines the title of a link, which appears to the user as a tooltip.

<a href="https://cstutorials1.blogspot.com/2020/10/how-to-create-links-to-sections-on-same.html" title="info_about_link">content visible as link</a>


target : Specifies where to open the linked URL. It can have 4 values.
  • _self - opens the linked URL inside same window or tab (default)
  • _top - opens the linked URL in top most frame of the window.    
  • _parent - opens the linked URL in parent frame of the window.
  • _blank - opens the linked URL in new tab or window.
download : Prompts the user to download the linked resource instead of opening in new tab/window.

<a href"address of file" download>content visible as link</a>

when passed without any value, filename will be suggested by browser. If you want to provide specific name to downloaded resource, pass some value to download attribute.

<a href"address of file" download="filename">content visible as link</a>

For live demo, go though below Youtube video:

Comments

Popular Posts

How to Import and Export Delimited Files, like CSV, in PowerShell

How to generate a GUID in PowerShell

PowerShell Arithmetic Operators