This topic contains a post which is marked as Best Answer. Press here if you would like to see it.
*

oscman

  • ****
  • 227 posts
[BUG] user can't delete account
« on: April 02, 2017, 05:37:29 PM »
Hello. When i delete my account it says it was successfuly deleted but the user is not deleted, i have backoffice manager pro and i have checked allow users to delete account

*

MB Themes

Re: [BUG] user can't delete account
« Reply #1 on: April 02, 2017, 08:34:43 PM »
@oscman
If you remove user from oc-admin, does it work without problem?
Is this problem related to backoffice manager plugin or to veronika theme?
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots

*

oscman

  • ****
  • 227 posts
Re: [BUG] user can't delete account
« Reply #2 on: April 03, 2017, 10:53:32 AM »
From oc-admin it works. I am not sure if its because of veronika or backoffice

Marked as best answer by oscman on April 03, 2017, 12:06:08 PM
*

MB Themes

Re: [BUG] user can't delete account
« Reply #3 on: April 03, 2017, 11:22:22 AM »
@oscman
It is problem of backoffice manager plugin.
Go to index.php of this plugin and find this line:
Code: [Select]
echo '<li class="opt_del_user"><a href="' . osc_base_url() . 'oc-content/plugins/backoffice_manager/delete_user.php?user_id=' . $user_id . '&secret=' . $user['s_secret'] . '" onclick="return confirm(\''  .__('Are you sure you want to delete your account? \nNote that all your listings will be deleted too! \n\nWould you like to continue', 'backoffice_manager') . '?\')">' . __('Delete account', 'backoffice_manager') . '</a></li>';
Replace it with:
Code: [Select]
echo '<li class="opt_del_user"><a href="' . osc_base_url(true) . '?page=user&action=delete&id='.osc_user_id().'&secret='.$user['s_secret'] . '" onclick="return confirm(\''  .__('Are you sure you want to delete your account? \nNote that all your listings will be deleted too! \n\nWould you like to continue', 'backoffice_manager') . '?\')">' . __('Delete account', 'backoffice_manager') . '</a></li>';
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots

*

oscman

  • ****
  • 227 posts
Re: [BUG] user can't delete account
« Reply #4 on: April 03, 2017, 12:06:05 PM »
Thank you it works

*

VS

  • **
  • 29 posts
Re: [BUG] user can't delete account
« Reply #5 on: August 29, 2023, 06:11:42 PM »
I also cant delete user from oc admin.
Why every time have new problem with osclass?
I need go to online with my site, but I have problems again.
What need to to check what is problem?
Also cant delete users from base.
I need urgently help!

*

MB Themes

Re: [BUG] user can't delete account
« Reply #6 on: August 29, 2023, 11:18:18 PM »
Most probably some blocking foreign key.
Go to database and try to remove that user from t_user table manually.
You should see error that tells which foreign key blocks it.
Uodate that key to ON DELETE CASCADE
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots