|
First, is that possible?
I'm able to give <tr> and <td> tags an ID but i can't seem to access them. Also, i tried created a div or span with an id inside the <td> tag but i couldn't access that either. At least with the innerHTML part of it.
jtax
|
|
|
Which browser you are using ?
In IE you can access the <TR> & <TD> tags of the table, provided every <TR> & <TD> has unique ID.
try following eg.
tdObj = document.getElementByID("TD_ID");
var txt = tdObj.innerHTML;
"TD_ID" - your ID for <TD>
|
|
|
Thanks, i had the problem where i was trying to affect the row's background (row had an id) but couldn't tell the difference because the column's backgroud color took precedence.
|
|
|
Hi,
Try this one, this will help you,
this is for your <TR>
trObj = document.getElementById("TR_ID");
trObj.style.backgroundColor = yourBGColor;
this will change the bgcolor of the row
|
|
|
|
|
|
|
© Copyright codetoad.com 2001-2004 |
|
|