How to align content in the center?
Currently the Header Text
and
the Login/Password Input fields
are not aligned in the center, and align seperately
Example:
"Header1"
"Header2"
...."login"
...."password"
...."buttons"
Header Fields:
<body> <div class="headerLogo" align="center"> <img src="images/login.png"><br><br><br> <h1 class="form-signin-heading"> <b>header1header1</b> </h1> <h3 class="form-signin-heading"> headerheader2 </h3> </div><br><br><br><br><br>
Login Input Fields:
<div class="container"> <form class="form-signin" method="Post"> <input type="text" id="email" class="form-control" placeholder="email"> <input type="password" id="password" class="form-control" placeholder="pwd"> <label class="checkbox"> <input type="checkbox" value="remember-me"> Keep Login </label> <button class="btn btn-lg btn-info btn-block" type="submit"> <b>로그인</b> </button> <div class="row"> <div class="col-md-6"> <a class="btn btn-lg btn-primary btn-block"><b>Email Join</b></a> </div> <div class="col-md-6"> <a class="btn btn-lg btn-primary btn-block"><b>Find Password</b></a> </div> </div> </form> </div> </body><!-- /container -->
try <div class="container" style="margin-right:30px"> if that doesn't work putting it onto jsfiddle would be helpful.
if you are using bootstrap and by the looks of you code you are, you can center text by adding the class "text-center".
<p class="text-center">aligned center</p> And some other useful alignments available in bootstrap :
<p class="text-left">aligned left</p> <p class="text-right">aligned right</p> <p class="text-justify">justified</p>
No comments:
Post a Comment