Win a copy of Svelte and Sapper in Action this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Bear Bibeault
  • Junilu Lacar
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • salvin francis
  • Frits Walraven
Bartenders:
  • Scott Selikoff
  • Piet Souris
  • Carey Brown

how to disable a div in firefox?

 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i had searched this forum but i cudnt find the solution..

the "document.getelementbyid.disabled=true " is not workin in firefox..

searched the net stil cant find a solution tat works..

can anyone help me asap
 
Ranch Hand
Posts: 349
Hibernate Eclipse IDE Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How to disable a div?

Or you are trying to hide a div?



This code could help you hide a div.

Ananth Chellathurai
 
preethi george
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
no i dont wanna hide it.. jus disable the radio buttons created in the div

ok the use case is!!
there are 2 radio buttons.. a and b ..
on clickin a table 1 sud b disabled and table 2 enabled..

on clickin b
table 1 disabled and table 2 enabled

 
preethi george
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
got it half way thru usin this code..

document.getElementById('unlimitedtab').addEventListener('click', function (event) { event.stopPropagation(); event.preventDefault(); return false }, true);

i really cant understand this code.. but it does the disabling part..
i now need to enable.. can it b done modifyin the abv code??
 
author
Posts: 15385
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please Use Real Words

Eric
 
Eric Pascarello
author
Posts: 15385
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A fair warning: That addEventListenerpart is not going to work in all browsers.

If you want to remove it, than you set the onclick to a blank function.

Eric




 
    Bookmark Topic Watch Topic
  • New Topic