English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية

Manual de referência HTML

大全 de etiquetas HTML

Propriedade sizes do link HTML

A propriedade sizes do link especifica o tamanho do ícone de mídia visual, usada apenas quando rel = "icon".

 HTML <link> tag

Exemplo online

Especificar o tamanho do ícone do link:

!DOCTYPE html
<html
<head
<title>HTML: Propriedade <link> sizes - Site de tutoriais básicos (oldtoolbag.com)<//title
title>codebox.com)</<link rel="icon" href="haha.gif" type="image16x16">
<body
<h2>Olá mundo! </h2>
</body>
</html>
Teste e veja ‹/›

Navegador compatível

IEFirefoxOperaChromeSafari

Currently, almost no mainstream browsers support the sizes attribute.

Definition and usage

link Sizes attribute specifies the size of visual media icons.

This attribute is used only when rel =" icon".

HTML 4.01 with HTML5difference

The sizes attribute is an HTML5 New attribute added in.

Syntax

<link sizes="HeightxWidth|any">

Attribute value

ValueDescription
HeightxWidthSpecify one or more sizes for the linked icon.
Height and width are separated by an "x" or "X".

Example s:

  • <link rel="icon" href="favicon.png" sizes="16x16" type="image/png"> (1 sizes)

  • <link rel="icon" href="favicon.png" sizes="16x16 32x32" type="image/png"> (2 sizes)

anySpecify that the icon is scalable (such as SVG images).

Example:

  • <link rel="icon" href="icon.svg" sizes="any" type="image/svg+xml"> (Any size)

 HTML <link> tag