Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
199 views
in Technique[技术] by (71.8m points)

html - Ensuring DIV within article tag fits properly?

This is the test page for a basic HTML template I've designed:

<html>
<head>
    <meta charset="utf-8" />
    <title>Used Cars of NYC</title>
<!-- <link rel="stylesheet" href="style.css"> -->
<style>
article.at1 {
    margin-left: 70px;
    float: left;
    border: 2px solid;
    border-radius: 12px;
    height: 200px;
    width: 640px;
} 
div.auto1 {
    display: table-row;
    float:left;
    column-span: 3;
    padding: 10px;
    margin-left: 40px;
    }
div.auto1:nth-child(1), div.auto1:nth-child(3) {
width: 150px;
}
div:nth-child(1) img {
  width: 180px;
  float: left;
  padding-left: 3px;
  margin-right: 20px;
}
</style>
</head>
<body>
<article class="at1">
<div class="auto1"><img src="https://hips.hearstapps.com/autoweek/assets/s3fs-public/sunburst-2.jpg"></div>
<div class="auto1"><h3>
PONTIAC SUNBURST
</h3>
<p>
This 1989 example is good condition
</p></div>
<div class="auto1">
$2,000
</div>
</article>
</body>
</html>
question from:https://stackoverflow.com/questions/65937440/ensuring-div-within-article-tag-fits-properly

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...