HTML文本输入不显示iPad键盘

时间:2012-06-11 20:18:59

标签: html css ipad jquery-ui html-input

所以,我有这段HT​​ML代码:

<input id= "email" type= "text" name= "email"/>

和CSS的相应片段:

input[type="text"]
{
    /* Padding */
    padding: 5px;
    margin: 10px;

    /* Sizes */
    width: 100%;

    /* Rounded Corners */
    -webkit-border-radius: 4px;
    -moz-border-radius: 4px;
    border-radius: 4px;

    /* Decoration */
    border: none;
    outline: none;

    /* Shadows */
    -moz-box-shadow: inset 0 1px 1px rgba(74, 74, 74, 0.8);
    -webkit-box-shadow: inset 0 1px 1px rgba(74, 74, 74, 0.8);
    box-shadow: inset 0 1px 1px rgba(74, 74, 74, 0.8);
}

当我点击输入元素时,没有任何反应。 iPad中没有显示键盘。

编辑:此网站正在使用jQuery,jQuery UI和jQuery UI Touch。

1 个答案:

答案 0 :(得分:1)

原来是这个问题:

http://code.google.com/p/jquery-ui-for-ipad-and-iphone/issues/detail?id=17

在jQuery UI Touch中,在函数

function iPadTouchHandler(event) {

在开关/案例中

    switch (event.type) {
        case "touchstart":

变化

            if ($(event.changedTouches[0].target).is("select")) {

            if ($(event.changedTouches[0].target).is("select") || $(event.changedTouches[0].target).is("input")) {

修复错误。

相关问题