This looks ok in IE but FF lengthens out the field set and legend. Also the Case County label seems to be a bit of a hack.
I am in a new shop where all input forms are tables, tr, td and would like to use css.
Any help or are most comments welcome.
Marty
I am in a new shop where all input forms are tables, tr, td and would like to use css.
Any help or are most comments welcome.
Marty
Code:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<TITLE> Input Form No tables </TITLE>
<style TYPE="text/css">
.BodyFont {
font-family: Arial, Helvetica, sans-serif, Verdana;
font-size: 0.7em;
background-color: #ECF8FF;
}
#container {
width: 100%;
border: 0.1252 solid Navy;
margin: 0.626em;
margin-left: auto;
margin-right: auto;
padding: 0.626em;}
#innercontainer {
width: 100%;
border: 0em;
margin-left: auto;
margin-right: auto;
padding: 0.626em;}
#innercontainer1 {
width: 100%;
border: 0em;
margin-left: auto;
margin-right: auto;
padding: 0.626em;
}
h1 {
font-family: Arial, Helvetica, sans-serif, Verdana;
font-size: 1.8em;
font-weight: bold;
text-align: center;
display: block;
color: Navy;
}
label {
font-family: Arial, Helvetica, sans-serif, Verdana;
font-size: 1.1em;
font-weight: bold;
width: 4em;
float: left;
text-align: right;
margin-right: 0.5em;
display: block;
color: Navy;
}
input
{
float: left;
background: #ffffff;
}
fieldset
{
width: 100%;
position: relative;
border: 0.2em solid Navy;
margin-left: auto;
margin-right: auto;
padding: 1em;
}
.fieldset1
{
width: 45%;
position: relative;
border: 0.1em solid Navy;
margin-left: 1.5em;
margin-right: 0.5em;
padding: 0em;
}
legend
{
font-size: 2em;
color: #fff;
background-color: #9ab4d1;
border: 0.1em solid Navy;
padding: 0.1252em 0.03756em;
}
.btn
{
font-family: Arial, Helvetica, sans-serif, Verdana;
color: White;
font-size: 1.2em;
font-weight: bold;
background-color: #9ab4d1;
}
</style>
</HEAD>
<BODY class="bodyfont">
<div id="container" name="container">
<h1>Input Form No tables</h1>
<div id="innercontainer" name="innercontainer">
<form action="#">
<fieldset>
<legend><span>Mother's Information</span></legend>
<div id="innercontainer1" name="innercontainer1">
<label for="name">Name</label> <input type="text" id="name" />
<label for="address">Street</label> <input type="text" id="address" />
<label for="city">City</label> <input type="text" id="city" />
<label for="state">State</label> <input type="text" id="state" />
</div>
<div id="innercontainer1">
<label for="phone">Phone</label> <input type="text" id="phone" />
<label for="e-mail">E-mail</label> <input type="text" id="e-mail" />
</div>
<input class="btn" type="button" value="Submit" /><input class="btn" type="button" value="Submit" />
</fieldset>
<fieldset>
<legend>Infant's Inormation</legend>
<div id="innercontainer1" name="innercontainer1">
<label for="infantName">Name</label> <input type="text" id="infantName" />
<label for="infantDOB">DOB</label> <input type="text" id="infantDOB" />
<a href="javascript:show_calendar('InfantInfo.infantDOB');" onmouseover="window.status='Date Picker';return true;" onmouseout="window.status='';return true;"/>
<img src="jsp/img/Cal_icon.gif" width=24 height=22 border=0></a>
<span class="fieldset1">
<label for="infantSex">Sex</label>
<label for="infantSex">Male</label><input type="radio" name="infantSex" id="infantSexM"/>
<label for="infantSex">Female</label><input type="radio" name="infantSex" id="infantSexF"/>
</span>
<span><b><font size="2" valign="top" color="Navy">Case County:</font></b>
<select name="mothersCaseCounty" class="RegSelect"></option><option value="001" >Albany</option><option value="003" >Allegany</option><option value="005" >Bronx</option><option value="007" >Broome</option><option value="009" >Cattaraugus</option><option value="011" >Cayuga</option></select>
</span>
</div>
<div id="innercontainer1" name="innercontainer1">
<input class="btn" type="button" value="Submit" /><input class="btn" type="button" value="Submit" />
</div>
</fieldset>
</form>
</div>
</div>
</BODY>
</HTML>