我有一个带有生日字段集的表单,我尝试了多个标记来强制字段在同一行中对齐。我试过显示:inline-block;排队;并且阻止没有运气。您将提供的任何帮助将不胜感激。谢谢!
这是我的字段集:
<fieldset class="birthday">
<label>Birthday</label>
<label class="month">
<select class="select-style" name="BirthMonth">
<option value="">Month</option>
<option value="01">January</option>
<option value="02">February</option>
<option value="03" >March</option>
<option value="04">April</option>
<option value="05">May</option>
<option value="06">June</option>
<option value="07">July</option>
<option value="08">August</option>
<option value="09">September</option>
<option value="10">October</option>
<option value="11">November</option>
<option value="12" >December</option>
</label>
</select>
<label>Day<input class="birthday" maxlength="2" name="BirthDay" placeholder="Day" required=""></label>
<label>Year <input class="birthyear" maxlength="4" name="BirthYear" placeholder="Year" required=""></label>
</fieldset>
这是我的css:
.quoteform2 fieldset.birthday {display: inline-block; border:0px; padding:0px; margin:0px;}
.quoteform2 label.month {width: 135px;}
.quoteform2 .select-style {
-webkit-appearance: button;
-webkit-border-radius: 2px;
-webkit-box-shadow: 0px 1px 3px rgba(0, 0, 0, 0.1);
-webkit-padding-end: 20px;
-webkit-padding-start: 2px;
-webkit-user-select: none;
background-image: url(images/select-arrow.png),
-webkit-linear-gradient(#FAFAFA, #F4F4F4 40%, #E5E5E5);
background-position: center right;
background-repeat: no-repeat;
border: 0px solid #FFF;
color: #555;
font-size: inherit;
margin: 0;
overflow: hidden;
padding-top: 5px;
padding-bottom: 5px;
text-overflow: ellipsis;
white-space: nowrap;}