From jira-events at lists.jboss.org Wed Jul 29 15:52:29 2009 Content-Type: multipart/mixed; boundary="===============2501108857625572564==" MIME-Version: 1.0 From: Rafael Rueda (JIRA) To: richfaces-issues at lists.jboss.org Subject: [richfaces-issues] [JBoss JIRA] Commented: (RF-2735) Error to clear node content by innerHTML when re-rendering Date: Wed, 29 Jul 2009 15:52:29 -0400 Message-ID: <1897596216.1248897149228.JavaMail.jboss@jira01.app.mwc.hst.phx2.redhat.com> In-Reply-To: 10203963.1206385138335.JavaMail.jira@cloud.prod.atl2.jboss.com --===============2501108857625572564== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable [ https://jira.jboss.org/jira/browse/RF-2735?page=3Dcom.atlassian.jira.= plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=3D12478137#a= ction_12478137 ] = Rafael Rueda commented on RF-2735: ---------------------------------- Hi, we solved this issue in our project. we use richfaces 3.3.1 version. We fix the file AJAX.js (richfaces-impl-3.3.1.GA.jar\org\ajax4jsf\javascrip= t\scripts). The solucion is to replace old code with the new code in the sp= ecific line. = Line: = 1394 Old Code: oldnode.outerHTML =3D new XMLSerializer().serializeToString( newnode ); New Code: if(Sarissa._SARISSA_IS_IE) { if( oldnode.tagName.match( /(tbody|thead|tfoot|tr|th|t= d)/i ) ) { LOG.debug( "Replace content of node by IE hack" ); var temp =3D document.createElement( "div" ); temp.innerHTML =3D '= '+new XMLSerializer().serializeToString( newnode )+'
'; anchor.replaceChild( temp.getElementsByTagName( new= node.tagName ).item( 0 ), oldnode ); } else if( oldnode.tagName.match( /(div|span|dd|dl|dt)/i = )) { var temp =3D document.createElement( "div" ); temp.innerHTML =3D new XMLSerializer().serializeToS= tring( newnode ); anchor.replaceChild( temp.getElementsByTagName( new= node.tagName ).item( 0 ), oldnode ); = } else { LOG.debug( "Replace content of node by outerHTML()"= ); oldnode.outerHTML =3D new XMLSerializer().serialize= ToString( newnode ); } = } > Error to clear node content by innerHTML when re-rendering = > ----------------------------------------------------------- > > Key: RF-2735 > URL: https://jira.jboss.org/jira/browse/RF-2735 > Project: RichFaces > Issue Type: Bug > Affects Versions: 3.2.0 > Reporter: Nick Belaevski > Assignee: Nick Belaevski > Priority: Minor > Fix For: Future > > > debug[20:56:36,276]: Such element exist in document > debug[20:56:36,289]: Attempt to update part of page for Id: j_id213:output > debug[20:56:36,303]: call selectSingleNode for id=3D j_id213:output > debug[20:56:36,318]: Replace content of node by outerHTML() > error[20:56:36,333]: Error to clear node content by innerHTML Unknown run= time error > debug[20:56:36,350]: search for elements by name 'script' in element inp= ut > debug[20:56:36,364]: selectNodes found 0 > debug[20:56:36,379]: Scripts in updated part count : 0 > debug[20:56:36,395]: Update part of page for Id: j_id213:output successful > debug[20:56:36,410]: Attempt to update part of page for Id: j_id213:j_id2= 14:29:j_id215 > debug[20:56:36,427]: call selectSingleNode for id=3D j_id213:j_id214:29:j= _id215 > debug[20:56:36,446]: Replace content of node by outerHTML() > error[20:56:36,461]: Error to clear node content by innerHTML Unknown run= time error > For page: > xmlns:ui=3D"http://java.sun.com/jsf/facelets" = > xmlns:h=3D"http://java.sun.com/jsf/html" = > xmlns:f=3D"http://java.sun.com/jsf/core" = > xmlns:a4j=3D"http://richfaces.org/a4j" = > xmlns:rich=3D"http://richfaces.org/rich"> = >

This tree uses "ajax" switch type, note that for collapse/expand opera= tions it will be Ajax request to the server. You may see short delay in thi= s case.


= > = > > = > = > = > = > = > = > = > = > = > = > = > = > = >
= -- = This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: htt= ps://jira.jboss.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira =20 --===============2501108857625572564==--