Why does the <a> tag represent links when an absolutely valid <link> tag exists?

There is probably a historical reason for this, but I do not know where to start looking for where this can be documented.

In particular, instead of the critical “anchor tag” with the “hypertext link” (well, I suppose then the terminology was different):

<a href="https://stackoverflow.com">StackOverflow</a>

why didn’t this happen?

<link to="https://stackoverflow.com">StackOverflow</link>

What exactly did “snapping” mean?

+4
source share
3 answers

According to W3 docs :

- - . "" "", - (, , , , , HTML, HTML ..).

, , - . , , .

+5

A , URL- ( <a name="myanchor">text</a>). text , A href #myanchor. A , , .

​​ , - .

. http://www.w3schools.com/tags/tag_a.asp

, , , Html , , , , , . , , , .

+4

, , CSS. - "", . "", , , , ( , #id).

+2

Source: https://habr.com/ru/post/1648312/


All Articles