I have a rich:dataTable and there i have a rich column with a span.
When the page is loading this span takes some values like: true+false or true+true etc.
Depending on this value, i hide the tr containing this span with jQuery like:
<rich:jQuery query="ready(function() {
jQuery('#inbox:_inboxTable_').find('span[title=test]').each(function(i, o){
if (jQuery(this).text() == 'true+false' ){
jQuery(this).closest('tr').fadeOut();
}
});
})"/>
All it’s working OK on Internet Explorer and Chrome but on Firefox is something strange:
– when the page is loading normally, the tr are hidden OK but when i do an ajax request (change the page number or size) ALL THE COMPONENTS from the page are faded out…
can u give me a clue?
Found the problem!!!
– closest(‘tr’) has harmfull behaviour in Firefox. So, instead of using:
the solution is to use parent by parent until you find the ‘tr’ of the span: