Doing destructive actions with a GET request


#1

I know that you should always use a POST to perform actions that are
destructive. I intend to break this rule and use a GET, but before I
do,
I’d like to know if there is a better way of doing this:-

I have an account edit form for the user to make changes to their
profile.
They have to be logged-in to do this. The problem is I have a
file_column field within the form which is storing an image - their
logo,
avatar, or whatever, and I need a button right there in the middle of
the
form for them to delete their logo if they wish. Obviously I can’t nest
a
form within a form, so I was going to make this a link to a
‘/user/delete_image’ action.

Is there a better way of doing this (without heavy javascript,
preferably)?

TIA,

Matt.


#2

just “post” a link_to_remote