Skip to main content
10 events
when toggle format what by license comment
Oct 15, 2020 at 11:25 comment added Rup Can you be more specific about what does not work - does your code not get called (can you verify that it does e.g. with some calls to error_log to trace?), do you get any errors, etc.? I can't see anything that looks like it would have changed, but I don't know WooCommerce or the admin site well.
Oct 15, 2020 at 11:24 comment added Rup Hi - you've posted this as a new answer, not a comment on Hector's post, so he won't get a notification about this. (I appreciate you don't have enough points here to post a comment there though.) I'm not sure what to suggest you do do, though - maybe ask a new question linking back to this one for context?
Oct 15, 2020 at 7:46 comment added ArchibaldTuttle Hector, I did add your code exactly, but sorting does not work, Is there any change in Wordpress code since then?
Oct 22, 2019 at 20:41 comment added Hector @fraudjeff you are welcome. If my solution worked and it answers your question, you can mark it as answer. So, others may get help for a same situation.
Oct 22, 2019 at 20:37 comment added fraudjeff You are the man! Thank you so much sir for your help, your code worked flawlessly; I am going to leave the extra column as well. Unfortunately, my upvotes don't do much as a new user, but you have my utmost gratitude!
Oct 22, 2019 at 20:12 comment added Hector @fraudjeff It will add a new column in admin->users. Like email column and shows count of orders for each user. You can keep the code or remove it. It will not affect users. It just displays information about users.
Oct 22, 2019 at 20:06 comment added fraudjeff …I think your solution of deleting from the dashboard is the proper way to go about this, but I am scared and would love some clarification first before I go and make any changes. After some research, I am led to believe that I would copypasta your code into the functions.php file, which I can find by navigating to Appearance>Editor tab in my wordpress dashboard. From there, I can paste your code into the file and save, navigate back to the Users tab, and only the users without admin/orders will show? Once done, I can just remove the code and be left with the users I want?
Oct 22, 2019 at 20:06 comment added fraudjeff Hector, I managed to get the query to work; I realized that I should be hitting GO instead of UPDATE :facepalm: I was unsure of how to add your elegant solution, so I first tried to delete the queried results in batches of 500; unfortunately, I am not seeing any changes in the user count on my wordpress dashboard when I navigate to the Users tab after making 2000 deletions from the ~14000 populated results via the query…
Oct 22, 2019 at 18:46 comment added fraudjeff Thank you Hector for the welcoming and detailed response! I really appreciate you taking the time to help explain this to a newbie like me; I will update this thread if I manage to have success!
Oct 22, 2019 at 18:39 history answered Hector CC BY-SA 4.0