0

I am using phone-gap(1.3) for android app development. How to add/remove classes in android OS in javascript. I tried this:

document.getElementById('delete_a').classList.add('whiteButton');
document.getElementById('delete_a').classList.remove('redButton');

But it is not working. Any help is appreciated. Thanks.

Nanashi
  • 155
  • 2
  • 14

1 Answers1

0

did you try this:

document.getElementById('delete_a').className = "whiteButton";

refer here

Community
  • 1
  • 1
Ashok Raj
  • 444
  • 6
  • 25
  • Can you give a little bit more explanation so the link isn't needed? If the link becomes old it might be difficult to understand your answer. – KLee1 Nov 13 '12 at 03:27