I am trying to implement a HTTP delete request from the user. So I got this in my HTML file,
<li><a href="/signout">Logout</a></li>
but in my routes file I got this:
match '/signout', to: 'sessions#destroy', via: :delete
and destroy is defined as:
def destroy
sign_out
redirect_to root_path
end
if I remove "via: delete" seems to work fine. But how do I invoke a DELETE method using HTML?