Change the "return key" in the iPhone WebApp text box

I am creating an iPhone webapp with a text box and would like to change the return key to "search". When you click on a text field, the keyboard pops up, and the return key in the lower right corner of the keyboard shows a "return" by default.

However, if you go to google.com on your iPhone and click on the search text box, “Go” will appear in the bottom right corner, and “Search” will appear in the yahoo.com search box. I tried looking at the google and yahoos source code but could not find any specific property that they use to do this.

This is a web application, not a native application.

** Update - 12/9/2011 **

Google.com search text box now displays “Search” for return key instead of “Go”

+3
source share
2 answers

Figured it out.

you need to add title = "Search" in the text box AND the text box should be in FORM tags.

Example:

<FORM ...>
   <INPUT TYPE="text" TITLE="Search" ...>
</FORM>
+10
source

iOS supports searchinput type :

<form>
    <input type=search>
</form>
0
source

Source: https://habr.com/ru/post/1717560/


All Articles