Display version: Css1/css2 Compatibility: ie4+ ns4+ Inheritance: None
Syntax:
Display:block | none | inline | Compact | Marker | inline-table | List-item | Run-in | Table |table-caption | Table-cell | Table-column | Table-column-group | Table-footer-group | Table-header-group | Table-row | Table-row-group
Parameters:
The default value of the Block:css1 block object. Add a new row after using this value as an object
None:css1 hidden objects. Unlike the hidden value of the visibility property, it does not retain its physical space for the object being hidden
Inline:css1 the default value of the inline object. Use this value to delete rows from the object
Compact:css2 allocates objects as block objects or inline objects based on content
MARKER:CSS2 specifies that the content is before or after the container object. To use this parameter, the object must be used with: after and: before pseudo elements
Inline-table:css2 table as inline object or inline container without wrapping
LIST-ITEM:CSS1 Specifies the block object as a list item. And you can add an optional item flag
Run-in:css2 allocates objects as block objects or inline objects based on content
Table:css2 the object as a block element level table
Table-caption:css2 the object as a table caption
Table-cell:css2 the object as a table cell
Table-column:css2 the object as a table column
Table-column-group:css2 the object as a table column group
TABLE-HEADER-GROUP:CSS2 displays objects as table header groups
Table-footer-group:css2 Display objects as table footer groups
Table-row:css2 the object as a table row
Table-row-group:css2 the object as a table row group
Description:
Sets or retrieves whether and how the object is displayed.
Currently, IE5.5 only supports the above CSS1 parameters.
The corresponding script attribute is display. Please refer to other bibliographies I have written.
Here's an example: click Show or hide
Copy Code code as follows:
<script language= "JavaScript" >
function Show (str) {
var I=documeng.getelementbyid (str);
if (I.style.display = = "None") {
I.style.display = "";
}
else{
I.style.display = "None";
}
}
</script>