PDA

View Full Version : cells Hide/show in each of the rows of a table using javascript


amarjit111
08-16-2010, 06:11 AM
Hi friends,

I have a table which is given below. If I select 'No' from the 'heading1' row, I want to hide 'Heading2', 'heading3' and 'heading4' in the same row. otherwise I select 'Yes' i want to show all the option in 'Heading2', 'heading3' and 'heading4'. Also in between if we select 'No' from the 'heading3' I want to hide 'heading4' alternatively if we select 'Yes' in 'heading3', i want to show 'heading4'.

I want to put this hide/show in each and every rows of this table.

I have tried many times but not able to write this code.
Can anyone in the forum help me in writing this code using javascript?


TABLE
________________________________________________________________________
| Heading1 |Heading2 | Heading3 | Heading4 |
________________________________________________________________________
| (.) Yes | Input box | (.) Yes | Input box |
| (.) No | | (.) No | |
________________________________________________________________________
| (.) Yes | Input box | (.) Yes | Input box |
| (.) No | | (.) No | |
________________________________________________________________________
| (.) Yes | Input box | (.) Yes | Input box |
| (.) No | | (.) No | |
________________________________________________________________________

Amarjit

Philip M
08-16-2010, 08:09 AM
See:- http://www.codingforums.com/showthread.php?t=17515.

You will not get any reply in this forum which is intended to be used only to
post a completed (working) script for showcasing/benefit of others.