HTML5. A vocabulary and associated APIs for HTML and XHTML4. Links. Links are a conceptual construct, created by a, area, and. Document. There are two kinds of links in. HTML Links to external resources. These are links to resources that are to be used to augment the current document. Hyperlinks. These are links to other resources that are generally exposed to the user by the user. For link elements with an href attribute and a. Similarly, for a and area elements with an href attribute and a rel attribute, links must be created for the keywords of the. Unlike link elements, however. This implied hyperlink has no special meaning it has no link type. A hyperlink can have one or more hyperlink. Links created by a and area elements. The href attribute on a and. URL potentially surrounded by. This is a comparison of image file formats. General. Ownership of the format and related information. rel shortcut icon icon href URI type imagevnd. microsoft. icon ICO. Notice. This is a draft document for public review. Overview. This document defines the OpenSearch description document, the OpenSearch Query element, the. The href attribute on a and. The target attribute, if present, must be. It gives the name of the browsing. User agents use this name when. When an a or area elements activation behavior is. In the absence of a user preference, the default should be navigation if the element has no. Whether determined by the users preferences or via the presence or absence of the attribute. These terms are defined in subsequent sections. The download attribute, if present. The. attribute may have a value the value, if any, specifies the default file name that the author. There are no restrictions on. The rel attribute on a and. The attributes value. The allowed keywords. The rel attribute has no default value. If the. attribute is omitted or if none of the values in the attribute are recognized by the user agent. The hreflang attribute on. It is. purely advisory. The value must be a valid BCP 4. BCP4. 7User agents must not consider this attribute authoritative upon. The type attribute, if present, gives the. MIME type of the linked resource. It is purely advisory. The value must be a. MIME type. User agents must not consider the type attribute authoritative upon fetching the. Following hyperlinks. When a user follows a hyperlink created by an element. Let replace be false. Let source be the browsing context that contains the. Document object with which subject in question is. If the user indicated a specific browsing context when following the hyperlink. Otherwise, if subject is an a or area element. If. these rules result in the creation of a new browsing context, set replace to true. Otherwise, if target is an a or area element. Document contains a base element with a target attribute, then let target be the. If these rules result in the creation of a new browsing. Otherwise, let target be the browsing context that subject itself is in. Resolve the URL given by the href attribute of that element, relative to that. If that is successful, let URL be the resulting absolute. URL. Otherwise, if resolving the URL failed, the. In any case, the user agent must then abort these steps. In the case of server side image maps, append the hyperlink suffix to URL. Queue a task to navigate the targetbrowsing context to URL. If replace is true, the navigation must be performed with replacement. The source browsing context must be source. The task source for the tasks mentioned above is the DOM manipulation task. Downloading resources. In some cases, resources are intended for later use rather than immediate viewing. To indicate. that a resource is intended to be downloaded for use later, rather than immediately used, the. The attribute can furthermore be given a value, to specify the file name that user agents are. This value can be overridden by the Content Disposition HTTP headers filename parameters. RFC6. 26. 6In cross origin situations, the download attribute. Content Disposition HTTP. This is to protect users from being made to download. When a user downloads a hyperlink created by an. Resolve the URL given by the href attribute of that element, relative to that. If resolving the URL fails, the user agent. In either case, the user agent must abort these steps. Otherwise, let URL be the resulting absolute. URL. In the case of server side image maps, append the hyperlink suffix to URL. Return to whatever algorithm invoked these steps and continue. Fetch. URL and handle the resulting resource. When a user agent is to handle a resource obtained from a fetch algorithm as. If the user agent needs a file name for a resource being handled as a download, it. This algorithm is intended to mitigate security dangers involved in downloading. Let filename be the void value. If the resource has a Content Disposition. RFC6. 26. 6Let interface origin be the origin of the. Document in which the download or. Let resource origin be the origin of the URL of the. URLs scheme. component is data, in which case let resource origin be. If there is no interface origin, then let trusted. Otherwise, let trusted operation be true if resource origin is the same origin as interface. If trusted operation is true and the resource has a Content Disposition header and that header includes file. RFC6. 26. 6If the download was not initiated from a hyperlink created by an. Let proposed filename have the value of the download attribute of the element of the. If trusted operation is true, let filename have. If the resource has a Content Disposition. RFC6. 26. 6No proposed file name If trusted operation is true, or if the. URL of the resource in a. Act in a user agent defined manner to safeguard the user from a potentially hostile. If the download is not to be aborted, then let filename be set to the users preferred file name or to a file name selected by. If the algorithm reaches this step, then a download was begun from a different origin than. This could be because a download attribute was used to trigger the download, or. This could be dangerous, because, for instance, a hostile server could be trying to get a. Thus, it is in the users interests that the user be somehow notified that the resource in. Sanitize Optionally, allow the user to influence filename. For. example, a user agent could prompt the user for a file name, potentially providing the value of. Adjust filename to be suitable for the local file system. For example, this could involve removing characters that are not legal in. If the platform conventions do not in any way use extensions to determine the types of file on the file system. Let claimed type be the type given by the resources Content Type metadata, if any is known. Let named. type be the type given by filenames extension, if any is known. For the purposes of this step, a. MIME type to an extension. If named type is consistent with the users preferences e. If claimed type and named type are the same type. Content Type metadata is. If the claimed type is known, then alter filename to. Otherwise, if named type is known to be potentially dangerous e. HTML. application, or executable macro capable document then optionally alter filename to add a known safe extension. This last step would make it impossible to download executables, which might not. As always, implementors are forced to balance security and usability in this. Return filename as the file name. For the purposes of this algorithm, a file extension. For example, many operating systems use the part of the file. User agents should ignore any directory or path information provided by the resource itself. URL, and any download attribute, in. Link types. The following table summarizes the link types that are defined by this specification. This. table is non normative the actual definitions for the link types are given in the next few. In this section, the term referenced document refers to the resource identified by the. To determine which link types apply to a link, a, or. The resulting tokens are the link types. Except where otherwise specified, a keyword must not be specified more than once per rel attribute. Link types are always ASCII case insensitive, and must be. Thus, relnext is the same as relNEXT. Some of the types described below list synonyms for these values. These are to be handled as specified by user agents, but must not be used. Link type alternateThe alternate keyword may be used with link. The meaning of this keyword depends on the values of the other attributes. If the element is a link element and the rel. The alternate keyword modifies the meaning of the stylesheet keyword in the way described for that keyword. The. alternate keyword does not create a link of its own. If the alternate keyword is used with the type attribute set to the value applicationrssxml or the value applicationatomxml.
|
AuthorWrite something about yourself. No need to be fancy, just an overview. Archives
November 2017
Categories |