Hi,

Im trying to find all the code that is related to 'user account and
all data deleted' in the account setting profile.

so far i only found this in the profiles_controller:
def destroy
    respond_to do |wants|
     @user.destroy
      cookies[:auth_token] = {:expires => Time.now-1.day, :value =>
""}
      session[:user] = nil
      wants.js do
        render :update do |page|
          page.alert('Your user account, and all data, have been
deleted.')
          page << 'location.href = "/";'
        end
      end
    end
  end

and this in the 'view/profiles/_form.html.erb:
<div id="delete_account">
      <h2><%= "Change Password" %></h2>

      <%= link_to_remote 'Delete my user account and all my
data.', :url=>profile_path
(@p), :method=>:delete, :confirm=>DELETE_CONFIRM  %>
  </div>

if i started a new project and add these two code in my controller and
views will it work?



--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Lovd by Less" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/lovdbyless?hl=en
Who loves ya baby?
-~----------~----~----~----~------~----~------~--~---

Reply via email to