Home > Web Front-end > JS Tutorial > jQuery on Screen Keyboard Plugin

jQuery on Screen Keyboard Plugin

Joseph Gordon-Levitt
Release: 2025-03-04 00:55:09
Original
516 people have browsed it

This jQuery on-screen keyboard plugin provides a customizable virtual keyboard for enhanced website usability. It's similar to Windows' accessibility keyboard, appearing when an input field is clicked.

jQuery on Screen Keyboard Plugin

Implementation:

  1. Download: Obtain the plugin files.
  2. Base Code: Use the provided demo.js as a starting point.
  3. Layout & Settings: Modify the keyboard layout and settings (see code examples below).
  4. CSS Styling: Customize the CSS to match your website's design.

Download & Demo Links: Download Page, Live Demo

jQuery Code Examples:

Basic QWERTY Keyboard:

$(document).ready(function(){
  $('.qwerty').keyboard({ layout: 'qwerty' });
});
Copy after login

Numeric Keyboard with Restrictions:

$(document).ready(function(){
  $('#num').keyboard({
    layout: 'num',
    restrictInput: true,
    preventPaste: true,
    autoAccept: true
  });
});
Copy after login

Typing Simulator Extension:

$(function() {
  $('.ui-keyboard-input').addTyping();
});
Copy after login

Keyboard Triggered by Hyperlink:

This example shows how to display the keyboard when a hyperlink is clicked, focusing a hidden input field:

$('.hiddenInput').click(function(){
  $('#hidden').trigger('focus');
  return false;
});

$('#hidden').keyboard({
  layout: 'qwerty',
  position: {
    of: $('.hiddenInput'),
    my: 'center top',
    at: 'center top'
  }
});
Copy after login

Remember to replace placeholder links with the actual download and demo URLs. This revised description provides a clearer and more concise explanation of the plugin's functionality and usage.

The above is the detailed content of jQuery on Screen Keyboard Plugin. For more information, please follow other related articles on the PHP Chinese website!

Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Articles by Author
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template