This is a simple yes or no question (probably no), googling didn't seem to give me a straight answer. Say you have a link that is
<a href="www.stackoverflow.com">www.stackoverflow.com</a>
Is it possible to make something like
<a href=self.text>www.stackoverflow.com</a>
without using anything else (obviously, no scripts)? Is there any kind of shortcut?
To make a hyperlink in an HTML page, use the <a> and </a> tags, which are the tags used to define the links. The <a> tag indicates where the hyperlink starts and the </a> tag indicates where it ends. Whatever text gets added inside these tags, will work as a hyperlink. Add the URL for the link in the <a href=” ”>.
Select the text that you want to turn into a hyperlink, and right-click it. On the shortcut menu, click Hyperlink. In the Insert Hyperlink dialog, paste the link in the Address box and click OK.
HTML Links - Syntax The most important attribute of the <a> element is the href attribute, which indicates the link's destination. The link text is the part that will be visible to the reader. Clicking on the link text, will send the reader to the specified URL address.
The href attribute specifies the URL of the page the link goes to. If the href attribute is not present, the <a> tag will not be a hyperlink. Tip: You can use href="#top" or href="#" to link to the top of the current page!
No, you need to have both the href
attribute and a value between the a
tags. Without using any scripts, it's not possible to refer to its own contents.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With