From http://www.w3schools.com (Copyright Refsnes Data)
The content property is used with the :before and :after pseudo-elements to generate content to attach before or after a CSS selector.
Inherited: No
CSS properties can also be dynamically changed with a JavaScript.
Scripting Syntax: object.style.content="url(beep.wav)"
In our HTML DOM tutorial you can also find a full Style Object Reference.
p:before { content: url("beep.wav") } img:before |
Value | Description |
---|---|
string | Defines text content. Default value is "" |
url | Defines a url |
counter(name) counter(name, list-style-type) counters(name, string) counters(name, string, list-style-type) |
|
attr(X) | Defines an attribute of a selector to be displayed before/after the selector |
open-quote | |
close-quote | |
no-open-quote | |
no-close-quote |
From http://www.w3schools.com (Copyright Refsnes Data)