+ 4
How to make img at center?
5 odpowiedzi
+ 9
<div align=center>
<img src="img.jpg">
</div>
+ 2
<center> tag element and 'center' tag attribute are deprecated in Html5.
You must use Css to align text and/or elements:
<div style="text-align:center;">
<img src="image.url" alt="description">
</div>
But you should prefer to avoid use of inlined style ( reserv them to dynamic use with JavaScript ), other than at building/debugging step ^^
- 1
its not working
- 1
<img align="center" src="index.jpg">
- 2
<html>
<head>
<title>first page</title>
</head>
<body>
<div align="center"><img src="http://www.sololearn.com/images/tree.jpg" alt="Image is loading"/> </div>
</body>
</html>