title: rails 3 - link_to to destroy not working
body: <p>I am trying to create a destroy link to my users controller, I am also using devise.</p>
  
  <p>Here is my code -</p>
  
  <h3>View</h3>
  
  <pre><code>&lt;%= link_to 'Delete User?', child, :confirm =&gt; "Are you sure you want to delete #{child.full_name}?", :method =&gt; :delete, :class =&gt; "user-additional", :style =&gt; "font-size:12px;font-weight:normal;" %&gt;
  </code></pre>
  
  <h3>Controller</h3>
  
  <pre><code>def destroy
   if @user = User.find(params[:id])
    @user.destroy
    respond_to do |format| 
      format.html { redirect_to account_index_path } 
      format.xml { head :ok } 
    end
   end
  end
  </code></pre>
  
  <h3>Routes</h3>
  
  <pre><code>devise_for :users 
  resources :users, :except =&gt; [:new]
  </code></pre>
  
  <p>The link translates to localhost:3000/users/10</p>
  
  <p>When clicked this opens the users show instead of deleting them</p>
  
  <p>Any ideas ?</p>