Displaying 1 result from an estimated 1 matches for "output_plot".
Did you mean:
output_log
2006 Apr 16
2
AJAX update of <img> element?
...o something like this...?
[View]
<%= form_remote_tag :url => {:action => ''sendplot''}, :update => ''plot'' %>
<%= submit_tag %>
<%= end_form_tag %>
<img id="plot" src="someimage.png"/>
[Controller]
def sendplot
output_plot(...) # this sends a png file to the browser - this bit works
end
I find that the browser (Opera or Firefox), no matter what, won''t :update an existing <img> tag. If I :update a <div> instead, I see the png data dumped as ascii, but that isn''t very useful!
Thanks,
Ch...