Leo Seyha
Leo Seyha

Reputation: 71

Hide iPhone's keyboard using Javascript

Does anyone know how to hide iPhone's keyboard in Safari after user touch button "Go" instead of "Done"?

I need solution for Javascript and HTML5.

Upvotes: 7

Views: 9410

Answers (1)

Gino
Gino

Reputation: 1854

With jQuery

You should unfocus the input from the button you click,

$("#button_id_clicked").click(function() {
    $("#search_input_id").blur(); // UNFOCUS THE INPUT                          
}); 

I use it on my web app

Upvotes: 8

Related Questions