Chrome表单输入不起作用

时间:2013-04-30 02:05:14

标签: jquery fancybox

这个问题对我来说完全是困惑的。 Chrome不允许我在我的服务器上运行Fancybox内部编辑表单字段或单击按钮。光标甚至不闪烁。在我的笔记本电脑上,灯箱右上方的“X”图标就在那里,但是当我在妈妈的笔记本电脑上测试它时,它没有显示出来。我有最新的FancyBox版本,我正在使用Jquery 1.9.1。 First example Second example

但是,如果我将JsFiddle用于我的代码,那么它可以运行。 我发现如果我调整浏览器窗口的大小,那么信息会显示出来。

这是表单的HTML:

<div style="display:none">
    <form id="question_form" method="post" action="">
        <p>Please enter your correct information so we can help you.</p>
        <p>
            <label for="fname">First Name:</label>
            <input type="text" id="fname" name="fname" size="30">
        </p>
        <p>
            <label for="lname">Last Name:</label>
            <input type="text" id="lname" name="lname" size="30">
        </p>
        <p>
            <label for="qmessage">Message:</label>
            <textarea id="qmessage"></textarea>
        </p>
        <p style="text-align: center;">
            <input type="submit" value="Submit">
        </p>
    </form>
</div>

我的Javascript:

$(document).ready(function () {
    $("#question_form_link").fancybox({
        'scrolling': 'no',
        'titleShow': true,
        'onClosed': function () {}
    });
}); //end ready 

编辑添加了tabindex属性 这是您多次按Tab键后看到的内容。 Weird thing, but you can actually type Looks normal and seems to work after browser window is resized.

0 个答案:

没有答案
相关问题