how to hide keyboard in jquery mobile programmatically on focus()

android, cordova, jquery, jquery-mobile, jquery-plugins

Solution

When submitting a form, at times, the iOS Keyboard may not automatically close. This is quite a usability issue as Users should not be required to manually close the Keyboard for use-cases in which they would otherwise not expect the need do so.

A simple solution for this can be implemented by invoking the blur method on document.activeElement, which effectively allows one to programmatically hide the keyboard:

// automatically close the keyboard on iOS
document.activeElement.blur();

More about HTML5 and Mobile application events ..

http://www.ericfeminella.com/blog/2012/12/27/ios-html5-input-element-tips/

Problem

I want to hide the keyboard on Focus(),but when `$(".ui-input-text").focus();` it will automatically open the keyboard . I just want to hide in particular screen ,I have test with `document.activeElement.blur();` but it also did not focus() on input .

Original source