Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 703577
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T03:50:47+00:00 2026-05-14T03:50:47+00:00

I have an on-screen keyboard in order to provide a safer input for passwords.

  • 0

I have an on-screen keyboard in order to provide a safer input for passwords.

The keyboard itself is placed like this:

<div class="teclado_grafico" id="teclado_grafico">
    <a class="tecla_teclado"  onmousedown="teclaAction( this, 'caja_selector'); return false" style="top: 0px; left: 0px;">Q</a>
    <a class="tecla_teclado"  onmousedown="teclaAction( this, 'caja_selector'); return false" style="top: 0px; left: 28px;">W</a>
.
.
.
</div>

And it has a “Shift button” which fires a JS function with this (I’ve already tried all that, indeed):

if (obj.innerHTML == "Mayus.") {
    try {
        MAYUSCULA_ACTIVADO = !MAYUSCULA_ACTIVADO;
        var tgrafico = document.getElementById("teclado_grafico");
        if(MAYUSCULA_ACTIVADO) {
//            tgrafico.className = "teclado_grafico mayuscula";
//            $("#teclado_grafico").removeClass('minuscula').addClass('mayuscula');
//            $("#teclado_grafico").attr('class', 'teclado_grafico mayuscula');
//            $("#teclado_grafico").attr('className', 'teclado_grafico mayuscula');
            tgrafico.setAttribute('className', "teclado_grafico mayuscula") ||
            tgrafico.setAttribute('class', "teclado_grafico mayuscula");
        } else {
//            tgrafico.className = "teclado_grafico minuscula";
//            $("#teclado_grafico").removeClass('mayuscula').addClass('minuscula');
//            $("#teclado_grafico").attr('class', 'teclado_grafico minuscula');
//            $("#teclado_grafico").attr('className', 'teclado_grafico minuscula');
            tgrafico.setAttribute('className', "teclado_grafico minuscula") ||
            tgrafico.setAttribute('class', "teclado_grafico minuscula");
        }
    } catch (_E) {
        //void
    }
    return;
}

The associated CSS is like this:

.mayuscula a.tecla_teclado{
    text-transform: uppercase;
}
.minuscula a.tecla_teclado{
    text-transform: lowercase;
}

It works on every single browser I’ve tried. IE 6, 7; Opera 10; GChrome; FF 3, 3.5 and 3.6; Safari 4,… but in IE8 v8 (strict mode) the class is not changed! I mean, debuggin’ with the IE8 tools allows one to see that the attribute className is there and it changes… but the user does not see the letters changing from uppercase to lowercase, to uppercase again.

I just don’t know how to handle this… I had complains about the client using IE6… now they updated their stuff and this shows up. Any help will be reaaaaly helpful!

EDIT Already tried suggestions of

tgrafico.className = MAYUSCULA_ACTIVADO ? "teclado_grafico mayuscula" : "teclado_grafico minuscula";

but no joy yet. Opening IE8 dev’s tools allows one to see in the HTML tab that the class is changing correctly between the expected values, but the browser just does not behave!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-14T03:50:48+00:00Added an answer on May 14, 2026 at 3:50 am

    I would try to use jquery and basically have all the keys lowercased and have css class

    .Upper {text-decoration:uppercase; }
    

    than the following code should work

    $('.shift').click(function(){ 
        $('.key').toggleClass('Upper');
    });
    

    Actually i have almost the same stuff, but not with text decoration property, and IE8 do update appearance of DOM elements on toggleClass
    Probably otherwise you should look what jQuery do on toggleClass in order to make it cross browser

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a touch screen keyboard in my WPF application and I would like
I have an application that acts like an on screen keyboard, I need it
I have a virtual keyboard class which implements a QWERTY alphanumeric only on-screen keyboard
I have a screen with pivot functionality, and I'd very much like just one
I have to make an on-screen keyboard using JAVA on linux. the problem is
I start the Windows On-Screen-Keyboard like that: s_onScreenKeyboard = new Process(); s_onScreenKeyboard.StartInfo = new
I'm having trouble with the on screen keyboard. I have an activity with an
I have a fullscreen DirectX desktop app, and would like to display the on-screen
I have a virtual on screen keyboard for a touch screen interface. I get
I have had an on-screen keyboard working fine for some time. I recently had

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.