I'm trying to update a user status to either enabled or disabled in the user database. I already have my toggle in place. When I view the user table from the dashboard, I want to be able to see the toggle button according to their status. I also want to be able to update their status using the same toggle.
I know it can be done with AJAX but I'm not sure about the implementation.
Anyone kind enough to enlighten me?