w3-video.com logo

HTML5 Tutorial

Home HTML5 XAMPP .htaccess Firefox Notepad++

Share it

link href attribute

The href attribute on the link element:



<linkattribute="value(s)" >Examples
1.href=URL<link rel="next" href="page2.php">

Video demonstration link href attribute

HTML5 link href attribute Tutorial

min video details
00:09 this video tutorial presents the href attribute on a link element
00:22 adding the <link> element to our document
00:27 adding the href attribute to link element
00:36 let's select a resource and link it to our html document: e.g. the main.css file
00:41 adding the resource's path as value of the href attribute, thus linking the resource to our page
00:48 a second example: linking another resource: e.g. the favicon.png
01:01 changing the url to point toward the new resource, the favicon
01:06 Note: the 2 resources were linked to our page but they don't display ⁄apply because their relationship (rel attribute » video ) with the current page has not been specified
01:15 rel attribute in this case is required
01:20 adding rel attribute to page, for example purpose; we've added the empty string "" value for simplicity because this video tutorial is not about rel attribute, BUT please note, the empty string is not a valid value for rel attribute; it must be one of the keywords defined by specs
link intro link optional link browser display link parents link examples & interpretation hyperlink vs external resource link link syntaxlink hreflang attributelink media attributelink rel attributelink type attributelink itemprop attributelink title attribute