Hi all, I am trying to put a form in the centre of the screen using CSS but not having much success and would be grateful of some help as i am sure it is a simple task but I am new to CSS, here is my code for the form:
and i am using the following CSS formatting
thanks in advance
Binary Intelligence, true or false?
Code:
<fieldset>
<legend>New Member Form</legend>
<form action="addnewmember.php" method="POST">
<label for="username">username
</label>
<input type="text" id="username" class="input-box" />
<br />
<label for="email">E-Mail
</label>
<input type="text" id="email" class="input-box" />
<br />
<label for"fname">First Name
</label>
<input type="text" id="fname" size="20" class="input-box" /> (Optional)
<br />
<label for"sname">Last Name
</label>
<input type="text" id="sname" size="20" class="input-box" /> (Optional)
<input type="submit" name="Submit" value="Add Details" class="submit-button" />
<br />
<a href="../">Cancel</a>
</form>
</fieldset>
and i am using the following CSS formatting
Code:
label
{
width: 10em;
float: left;
text-align: right;
margin: 0 1em 10px 0;
clear: both
}
.input-box
{
margin-bottom: 10px;
color: #26a;
background: #feb;
border: #26a solid 1px
}
.submit-button
{
margin-left: 5em;
clear: both;
color: #000;
background: #fb0;
border: 2px #9cf outset
}
fieldset
{
border: #26a solid 1px;
width: 30em;
padding-left: 1em;
}
legend
{
background: #fb0;
border: #26a solid 1px;
padding: 1px 10px;
}
Binary Intelligence, true or false?