We would like to know how to text-align: center; Center images/paragraphs/buttons.
<!DOCTYPE html>
<html>
<head>
<style type='text/css'>
#center {<!--from ww w . jav a2 s .c o m-->
background-color: red;
text-align: center;
}
</style>
</head>
<body>
<div id="center">
<button>button1</button>
</div>
</body>
</html>
The code above is rendered as follows: