Displaying 1 result from an estimated 1 matches for "post_edit".
Did you mean:
list_edit
2006 Apr 29
0
Trouble with firefox and AJAX
...# Post handling
def post_view
if params[:id]
@post = Post.find(params[:id])
render :partial => "post", :object => @post
else
# Do nothing for an unsaved post
render :nothing => true
end
end
def post_edit
if params[:save]
# Create and save a Post from the form details
@post = Post.new params[:post]
if @post.save
render :partial => "post", :object => @post
end
else
# Create a new Post or load...