'Second <div> tag failing to show up with color
I'm trying to create an animation with 2 div tags, but the child is not appearing in the parent. How do I get the child to show up with background color?
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>Rotate</title>
</head>
<body>
<style>
.parent {
width: 400px;
height: 400px;
background-color: hsla(200,100%,20%);
};
.child {
width: 50%;
height: 50%;
background-color: red;
z-index: 2;
};
</style>
<div class = "parent">
<div class = "child"></div>
</div>
</body>
</html>
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
