1. Due to the recent site upgrade, the iPadForums (iPF) App will no longer work. The new iPadForums.net website has been designed from the ground up to work perfectly from any mobile, tablet, or desktop computer using the built in internet browser. Create a shortcut to iPadForums.net on your home screen by following these steps: Create an icon for iPadForums.net

A strange question on ipad's safari

Discussion in 'iPad Development' started by pandajj, Feb 10, 2011.

  1. pandajj
    Offline

    pandajj iPF Noob

    Joined:
    Feb 10, 2011
    Messages:
    1
    Thanks Received:
    0
    Trophy Points:
    0
    Ratings:
    +0 / 0
    Code:
    <!DOCTYPE HTML>
    <html>
        <head>
            <title>form</title>
            <style type="text/css">
                .tel{
                    -webkit-transition:all .3s ease-in-out;
                    position:absolute;
                    height:40px;
                }
            </style>
        </head>
        <body>
            <input type="text" id="tel" class="tel" style="top:10px"/>
            <s cript type="text/javascript">
                var input=document.getElementById("tel");
                input.onfocus=function(){
                    input.style.top="50px";    
                }
                input.onblur=function(){
                    input.style.top="10px";
                }
            </script>
        </body>
    </html>
    Hello, i meet a strange question today.
    Those codes work fine on computer's safari. But when i try it on ipad's safari, the input's focus does not slide down with the text input element.
    How can i fix it?

Share This Page

Search tags for this page
ipad body onblur
,
ipad how to select() all input onfocus
,

ipad onblur

,

ipad onfocus

,
ipad onfocus css
,

ipad safari input focus

,
ipad safari input select text
,
ipad safari javascript select text
,
ipad safari onfocus
,
ipad select input text
,
iphone safari input onfocus
,
onblur on ipad safari
,
safari focus on field ipad