Can anyone verify that you can’t update a tbody element in IE 6 by using
I’ve tried all three ways I know to update the innerHTML property of the
tbody and it won’t take.
But page[‘name’].insert_html works fine.
Just look for corroboration.
Wes G. wrote:
Can anyone verify that you can’t update a tbody
element in IE 6 by using page[‘name]’.replace_html?
It’s true for all IE versions. IE uses MS Table DOM, not the W3C DOM. or
There’s an explanation on MSDN. You can replace a tbody, you can insert
another tbody above or below, but you basically can’t do anything via
with an existing
. I think you can update a
| if that
does anything for you. Not 100% sure of all the caveats on that though.
I guess this was why I got that error with the Dojo FilteringTable on
Good info. Thanks! I’ll put this in the Save folder.
What I needed to do was to replace a whole set of rows (in a datagrid)
with another set.
Luckily, IE does follow DOM level 2 (at least for what I needed), and I
element will change), and then doing a "page.insert_html" to the
bottom of the tbody (which will at that point have no rows in it).
solved my problem by deleting each row from the bottom up (you have to
do it from the bottom up or the relative indexing of rows within the
It is a pain in the arse, but it does work in both IE and FF.
XSLDatagrid::ROWS_TO_DISPLAY is the number of rows in the tbody named
Here’s the code:
render :update do |page|
(0…XSLDatagrid::ROWS_TO_DISPLAY - 1).to_a.reverse.each do |index|
I have such mixed feelings about this project, it causes me so much
grief but then I always end up learning something useful by overcoming
all these ridiculous f-in’ problems ;).