Displaying 1 result from an estimated 1 matches for "replace_html_element".
2005 Dec 15
0
RJS Templates and the Replace semantics
...dding the element:
page.remove "thing-id"
page.insert_html :bottom, :partial => ''thing''
I don''t like either of these ideas, so I came up with an improvement
that replaces the entire element in the DOM, similar to IE''s
element.outerHTML:
page.replace_html_element "thing-id", :partial => ''thing''
So, I''ve written an implementation of replace_html_element that comes in
two parts:
* The addition to the JavaScriptGenerator class to add a
replace_html_element method
* An update to the Prototype Element implementation t...