Please note, this is a STATIC archive of website developer.mozilla.org from 03 Nov 2016, cach3.com does not collect or store any user information, there is no "phishing" involved.

CSS Examples: display

Examples

A list with "..." added with an after marker:

  1. One
  2. Two
  3. Three

Example of a display: block element

Example of a display: inline element

Styles Used

li:after {
	display: marker;
	content: "...";
}
.header {
	color: black;
	padding-top: 0.25em;
	border-top: 3px solid black;
}
.header:before {
	display: block;
	color: gray;
	content: "New Chapter";
	margin-bottom: 0.5em;	
}
.header2 {
	color: black;
	padding-top: 0.25em;
	border-top: 3px solid black;
}
.header2:before {
	display: inline;
	color: gray;
	content: "New Chapter";
	margin-bottom: 0.5em;	
}