我在使用Bootstrap的表单中有两个内联单选按钮。但是当我验证它然后显示第一个单选按钮内部的消息而不是在第二个单选按钮后显示。我想显示电子邮件和密码等单选按钮消息。这是我表格的截图。
HTML表单:
<form name="registration" action="">
<div class="signingInner">
<h4 style="font-weight: 500; text-align:center; font-size: 20px ">Sign in to your Account</h4>
<div class="form-group">
<label for="emailId">Email Address:</label>
<input type="text" class="form-control" id="login_email" name="login_email" placeholder="Please enter Email address">
</div>
<div class="form-group">
<label for="pwd">Password:</label>
<input type="password" class="form-control" name="login_password" id="login_password" placeholder="●●●●●●">
</div>
<div class="form-group">
<div class="radio-inline" style="padding-left: 100px;">
<input type="radio" id="user" name="LoginMode" value="user" >
As <strong>User</strong> </>
</div>
<div class="radio-inline" style="padding-left: 30px;">
<input type="radio" id="company" name="LoginMode" value="company" >
As <strong>Company</strong></>
</div>
</div>
<input type="submit" name="btnLogin" class="btn btn-lg btn-primary btn-block" value="Login"></input>
</div>
</form>
Plunker Link: https://plnkr.co/edit/0vpvU9QbRu8Mlwbi04ti?p=preview
答案 0 :(得分:1)
诀窍是使用SELECT hr_employees1.FirstName, hr_employees1.LastName, wagetypes1.Description,
SUM(wagetypeweight1.quantity), wagetypeweight1.date, wagetypes1.factor
FROM nomina_pelado.wagetypes wagetypes1
INNER JOIN (nomina_pelado.hr_employees hr_employees1
INNER JOIN nomina_pelado.wagetypeweight wagetypeweight1
ON hr_employees1.Employee=wagetypeweight1.employee)
ON wagetypes1.WageType=wagetypeweight1.wagetype
WHERE wagetypes1.factor='N'
group by hr_employees1.Employee, DATE(wagetypeweight1.date)
回调函数。
所以我正在检查呈现的类型是否是单选按钮然后我正在跟踪相应的最顶层父div并在此之后插入消息。
errorPlacement
请参阅更新后的 plunkr here 。
编辑:
我终于更新了您提供的original plunkr。