0
how to center an image using html?
<img src="photo.jpg" height="240px" width="320px" align="center"> align="center" dose not work.
3 odpowiedzi
+ 6
The align attribute of <img> is not supported in HTML5.
Try this:
<div style="text-align:-webkit-center" >
<img src="photo.jpg" height="240px"
width="320px">
</div>
+ 2
you should type:
<style>
figure {
display: inline-block ;
text-align: center ;
}
</style>
in the head
0
Here is an example using flexbox
https://code.sololearn.com/WQt9QH8Q20Dn/?ref=app