I want to make the form looks 1200px in width. However, when I set width in class .container or .form-group, or even in form tag, it won't work. Only when I set width in textarea tag will it work. What is the problem?
index.html
<!DOCTYPE html>
<html>
<head>
<link href="style.css" rel="stylesheet">
</head>
<body>
<div class="container">
<form>
<div class="form-group">
<textarea class="status-box"></textarea>
</div>
</form>
</div>
</body>
</html>
style.css
.container {
width: 1200px;
margin-top: 20px;
}
type="text/css".containerto be 1200px width? In that case your CSS works fine - jsfiddle.net/0h5pbaLs