Behavior
Talk0
645pages on
this wiki
this wiki
The CSS behavior property specifies one or more space separated URLs indicating script(s) to attach to a CSS selector. It sets the location of the DHTML (Dynamic HTML) behavior. Behaviors allow the default functionality of a given element to be extended. Using simple CSS syntax that allows script to be separated from style and content, CSS behaviors offer a fairly elegant and efficient way to re-use script code.
Values
Edit
| Value | Description |
|---|---|
url(url) | Provides an absolute or relative URL reference to the behavior. |
url(#object_id) | The behavior is a binary implementation. This syntax consists of a hash sign (#) followed by an <object> element id within the document that instantiates the binary implementation.
|
url(#default#behavior_name) | This syntax allows each default behavior to be easily referenced. |
HTML example:
<blockquote style="behavior:url('hilight.htc') url('#behaveBinObject');">
To be or not to be, that is the question.</blockquote>
CSS example:
blockquote {
behavior:url("hilight.htc") url("#behaveBinObject");
}