Jquery 虚拟键盘插件的位置
我正在使用这个插件(http://www.jquery4u.com/plugins/jquery-screen-keyboard-plugin/#.UCTg6p1lTkd)为信息亭创建屏幕键盘。它工作得很好,但是我需要键盘出现在屏幕底部,而不是在输入/文本区域下方 在外部jquery.keyboard.js文件中,我发现了以下内容:Jquery 虚拟键盘插件的位置,jquery,jquery-ui,virtual-keyboard,Jquery,Jquery Ui,Virtual Keyboard,我正在使用这个插件(http://www.jquery4u.com/plugins/jquery-screen-keyboard-plugin/#.UCTg6p1lTkd)为信息亭创建屏幕键盘。它工作得很好,但是我需要键盘出现在屏幕底部,而不是在输入/文本区域下方 在外部jquery.keyboard.js文件中,我发现了以下内容: $.keyboard.defaultOptions = { // *** choose layout & positioning ***
$.keyboard.defaultOptions = {
// *** choose layout & positioning ***
layout : 'qwerty',
customLayout : null,
position : {
of : null, // optional - null (attach to input/textarea) or a jQuery object (attach elsewhere)
my : 'center top',
at : 'center top',
at2: 'center bottom' // used when "usePreview" is false (centers the keyboard at the bottom of the input/textarea)
},
我应该使用什么来代替“null”?如何将其添加到代码中
感谢提供参数的
,只需指向文档窗口:$(窗口)
以下是您的姓名和代码:
$('#keyboard').keyboard({
// Used by jQuery UI position utility
position: {
of: $(window), // null = attach to input/textarea; use $(sel) to attach elsewhere
my: 'center bottom',
at: 'center bottom',
at2: 'center bottom' // used when "usePreview" is false
}
});
由于这是一个信息亭,您可能还需要检查键盘的位置和大小。此外,键盘中还添加了“上一步”和“下一步”按钮。。。嗯,我发誓有上一个和下一个按钮。我需要更新那个演示
注意:我为虚拟键盘添加了一个标签,因为我完全没有回答这个问题。另外,请务必查看