How to close the window on def update?


#1

hey all,
I have my usual update function like this:
def update
@document = Document.find(params[:id])
if @document.update_attributes(params[:document])
flash[:notice] = ‘Document was successfully updated.’
redirect_to :action => ‘show’
else
render :action => ‘edit’
end
end

I would like to change:
redirect_to :action => ‘show’
with:
something “window.close()”

any idea?

Thanx in advance


#2

for those who care, this is how I fixed it:
render :text => '’