-2

How to align text and images inside tag in the middle?

<html>
<head>
<body bgcolor = "lavender">
<fieldset style="border-color:blue;">
 <img id="image1" src="bed.jpg" height=250 width=250>
 <img id="image2" src="bed.jpg" height=250 width=250>
<img id="image3" src="bed.jpg" height=250 width=250>
<img id="image4" src="bed.jpg" height=250 width=250>
<img id="image5" src="bed.jpg" height=250 width=250>
</fieldset>
Patrick Q
  • 6,373
  • 2
  • 25
  • 34

1 Answers1

0

img {
display: block;
margin: 0 auto;
height:250px;
width:250px;
}
<fieldset style="border-color:blue;">
<img id="image1" src="bed.jpg">
<img id="image2" src="bed.jpg">
<img id="image3" src="bed.jpg">
<img id="image4" src="bed.jpg">
<img id="image5" src="bed.jpg">
</fieldset>

Is this what you want?