How about using Xpath from Javascript to find the nodes? Very simple. -- Jonathan Rosenberg Founder & Executive Director, Tabby's Place http://www.tabbysplace.org/
-----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of Jelks Sent: Tuesday, April 20, 2010 9:39 AM To: Prototype & script.aculo.us Subject: [Proto-Scripty] Re: Hide or Remove non-HTML element from HTML Let me rephrase the question... Given that this is generated: <form ...> <input ...> <AsyncException>Error occured during AsyncInvocation.</ AsyncException> <some more real html form stuff...> </form> In the IE HTML DOM, that XML snippet becomes three "nodes": ASYNCEXCEPTION #text ("Error occured during AsyncInvocation.") /ASYNCEXCEPTION Is there a way in IE to iterate through all the text nodes, and when it find one that contains say "AsyncInvocation", remove the whole text node, or perhaps replace the whole text node with ""? So far I've always addressed text nodes through their parents/ wrappers, but maybe there is a way to address them directly? Alternately, perhaps there is a way to address that "ASYNCEXCEPTION" node and address the next sibling, which is presumably the text node, and set it to blank. I know this is an edge case and deals with IE weirdnesses, but perhaps someone here has dealt with this before. Many thanks, Jelks -- You received this message because you are subscribed to the Google Groups "Prototype & script.aculo.us" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/prototype-scriptaculous?hl=en. -- You received this message because you are subscribed to the Google Groups "Prototype & script.aculo.us" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/prototype-scriptaculous?hl=en.
