Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CSS

Creating Intrinsic Ratios

#containingBlock {
	width: 50%;
}

.videoWrapper {
	position: relative;
	padding-bottom: 56.25%;
	padding-top: 25px;
	height: 0;
}

object,
embed {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
}
Source by alistapart.com #
 
PREVIOUS NEXT
Tagged: #Creating #Intrinsic #Ratios
ADD COMMENT
Topic
Name
3+6 =