HTML and CSS Reference
In-Depth Information
As an example, consider an HTML document at
.html , which has a link to the style sheet :
<link rel="stylesheet" type="text/css"
Inside the file basic.css is an @import statement referring to another style sheet:
@import url(special/toppings.css);
This @import will cause the browser to look for the style sheet at
styles/special/toppings.css , not at . If
you have a style sheet at the latter location, then the @import in basic.css should read:
@import url(;
Note that there cannot be a space between the url and the opening parenthesis:
body {background: url(http://www.pix.web/picture1.jpg);} /* correct */
body {background: url (images/picture2.jpg);} /* INCORRECT */
If the space is present, the entire declaration will be invalidated and thus ignored.
An image value is a reference to an image, as you might have guessed. Its syntax rep-
resentation is <image> .
At the most basic level of support, which his to say the one every CSS engine on the
planet would understand, an <image> value is simply a <url> value. In more advanced
user agents, <image> stands for one of the following:
A URL identifier of an external resource; in this case, the URL of an image.
Perhaps unsurprisingly, a list of images. As of mid-2012 there was no support for
this value type.
Refers to an element within the document. The element is then copied and used
as an image, possibly as a “live” copy—that is to say, a copy that updates if the
element is altered through Dom scripting or user interaction. As of mid-2012, only
Firefox supported this capability.
Refers to either a linear or radial gradient image. Gradients are fairly complex.
Search WWH ::

Custom Search