Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

column hide mozilla display javascript  RSS feed

 
Akhilesh Trivedi
Ranch Hand
Posts: 1608
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How di i hide a table column in mozilla javascript.i am able to hide it either by display : "none" or visibility:"hidden"
but the problem is in re-showing the same.

td.styledisplay="table-column";//does it work?? td.style.visibility="visible";
[ December 27, 2006: Message edited by: Bear Bibeault ]
 
Muhammad Saifuddin
Ranch Hand
Posts: 1325
Android Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I got the References of these two elements of style with following keywords those you can use with in this property.

style.display
style.visibility

hope its helps.
 
Neerav Narielwala
Ranch Hand
Posts: 106
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
document.getElementByID.style.display="none" should work out..
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 66144
146
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
As Neerav pointed out, display is the rule you seek, not visibility.
 
Akhilesh Trivedi
Ranch Hand
Posts: 1608
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Above code works fine when i use tr id = hide_someindex. and it works fine in both IE and Firefox.

However when i use above code for td id = hide_someindex , it gives trouble in Firefox.
 
Akhilesh Trivedi
Ranch Hand
Posts: 1608
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
please change the onlod event ('a' intentionally removed due to some error.) before trying the code in browser.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!