Test of iPhone Go
[pazpar2-moved-to-github.git] / www / iphone / go.html
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">  
2 <html>  
3   <head>  
4   <meta name="viewport" content="width=320; user-scalable=no" />  
5   <meta http-equiv="Content-type" content="text/html; charset=utf-8">  
6   <title>Safari Mobile input test page</title>  
7   <script>  
8   function handleKeyPress(e)  
9   {  
10     var key;  
11     if(window.event)  
12       key = window.event.keyCode;  
13     else  
14       key = e.which;  
15   
16     if(key == 13 || key == 10)  
17     {  
18       document.forms[0].submit()  
19       document.getElementById('testLink').focus();  
20       return false;  
21     }  
22     else  
23       return true;  
24   }  
25   </script>  
26 </head>  
27 <body>  
28   <form action="javascript:alert('search')">  
29       <input type="text"  
30          onKeyPress="return handleKeyPress(event)"  
31           maxlength="100"  
32                    value="" />  
33       <a href="#" id="testLink"></a>  
34     </form>  
35   </body>  
36 </html>