Search notes:

HTML element: a

An <a> element with a href attribute represents a hyperlink.

Attributes specific to the <a> tag

Besides the global attributes, the <a> element has these specific attributes:

Removing underlines

The underlines of an <a> element can be removed by setting the CSS attribut text-decoration to none:
<style>
a {
  text-decoration: none;
}
</style>
…
<a href='xyz.html'>xyz</a>

Calling a JavaScript function when clicking the element

There are essentially two ways to call a JavaScript function by clicking on a <a> element:
<a href='javascript:alert("hello world")'>Click me</a>
<a href='#' onclick='alert("good by"); return false;'>follow me</a>

Misc

In the HTML DOM API, the <a> element is, inconsistently, represented by an HTMLAnchorElement (not an HTMLAElement).
HTMLLinkElement is the DOM interface for the <link> element.
See also HTMLElement inheritance).

See also

document.links
«Invisible» links can be formulated with the <link> element.
The CSS pseudo selector :target selects the currently clicked target (attribute id) HTML element.
HTML elements

Index

Fatal error: Uncaught PDOException: SQLSTATE[HY000]: General error: 8 attempt to write a readonly database in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php:78 Stack trace: #0 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(78): PDOStatement->execute(Array) #1 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(30): insert_webrequest_('/notes/developm...', 1759397918, '216.73.216.42', 'Mozilla/5.0 App...', NULL) #2 /home/httpd/vhosts/renenyffenegger.ch/httpsdocs/notes/development/web/HTML/tags/a(89): insert_webrequest() #3 {main} thrown in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php on line 78