I want to position the plus symbol in the below smack in the middle of the circle. Now i tried using top , left properties. That worked only for one device. When I view the page on a smartphone, all is lost. So I need a method position without using top and left and such that moving the circle will not affect the plus(it will remain in the center).
My code :
<html>
<body>
<div id="button"><div id="plus">+</div></div>
</body>
<style>
#button
{
position : relative;
width : 100px;
height : 100px;
border-radius : 100%;
background-color : red;
}
#plus
{
display : inline-block;
position : absolute;
width : 50%;
height : 50%;
margin : auto;
left : 5px;
font-family : sans-serif;
font-size : 40px;
color : black;
vertical-align : middle;
text-alignment : center;
}
</style>