Php 单击引导中的标签时,文本框不应聚焦
我使用了jQuery验证。并使用twitter bootstrap 2.3.2。单击“提交”按钮时将显示错误消息。如果单击错误消息,则表示文本框已聚焦。我怎么会失去焦点Php 单击引导中的标签时,文本框不应聚焦,php,jquery,Php,Jquery,我使用了jQuery验证。并使用twitter bootstrap 2.3.2。单击“提交”按钮时将显示错误消息。如果单击错误消息,则表示文本框已聚焦。我怎么会失去焦点 <input type="file" name="type1" id="type1"> <label for="type1">This field is required</label> 此字段必填 您可以尝试以下方法: $(function(){ $('input').blur();
<input type="file" name="type1" id="type1">
<label for="type1">This field is required</label>
此字段必填
您可以尝试以下方法:
$(function(){
$('input').blur();
});
使用以下命令:
<input type="file" name="type1" id="type1">
<label for="type1" onmousedown="return false;" onclick="return false;">This field is required</label>
此字段必填
onlcick和onmousedown“return false;”将禁用默认浏览器行为。欢迎使用SO。为了能够帮助您,我们需要您向我们展示您的代码!此字段是必需的,我无法使用它。因为标签是在jQuery验证中自动生成的:(