• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

XF 1.5 Best way to Delete a User and All their Posts?

XenBurger

Active member
#1
One of those questions that has been asked a thousand times, but Google wasn't helping:

Is the "Spam" feature the best way to delete a user amicably, when they request it, including deleting all their posts?

Just uncheck the "ban" option?

Or is there a method for this type of situation that accomplishes all those goals without the "spam hammer".

It just seems so aggressive :)

Thx
 
#3
Just wanted to revisit this. When a user emails me saying "Please delete my account" - I want to intuitively go into the admin, search their username, and click "Delete user".

But for some weird reason doing this does not delete them.

In fact it leaves both their username visible all over the forum, and leaves all their posts in tact also. I am not clear why this constitutes "Deleting a user" to the XF system.

It literally does nothing but disable their login and put the word "Guest" beneath their unaffected username.

So lets rewire my brain.

Right now you are expected to search for posts manually on the forum front end, hope that user has even created a post, and then - what - mark them as spam to delete their account and content?

That does not make sense to me.

And what if the user has not posted at all? How then do we find them in the first place to execute the "Spam" delete functions?

Users consistently want 1) Their username deleted 2) All their content deleted.

It would be okay if their posts were flipped to GUEST, but that doesn't happen. The username stays in tact.

How do I delete users with and without posts, so their username does NOT appear anywhere on the site, and any content they may have posted is also removed?
 
Last edited:

Optic

Well-known member
#4
Hi @XenBurger ,


How do I delete users with and without posts, so their username does NOT appear anywhere on the site, and any content they may have posted is also removed?
If you adjust the SPAM Cleaner criteria all to 0 it can be made available at all times:

From the documentation:
The Spam Cleaner can be made available for use on members, based on message count, elapsed days since registering, and the number of Likes that member has received. This is configured via the Spam Cleaner User Criteria option.

To make the Spam Cleaner available at all times, set all three values to 0.

And what if the user has not posted at all? How then do we find them in the first place to execute the "Spam" delete functions?
The Spam Cleaner itself can be run from several locations:
  • On a thread or profile post by clicking the Spam link to the right of the time and date.
  • On a member card by clicking the Spam link which overlays the avatar.
  • On a profile page by clicking the Spam link in the Moderator Tools menu.

Users consistently want 1) Their username deleted 2) All their content deleted.

It would be okay if their posts were flipped to GUEST, but that doesn't happen. The username stays in tact.
This really comes down to the way forums are designed and a design issue depending on how you look at it.

Because members can be quoted, and tagged/mentioned in a number of threads it really breaks the flow of a thread if their content is suddenly removed - especially if other members are replying to quoted members. It's not easy to remove this content if they were an established member.

With this in mind:
  • IMO it's probably easier just to CHANGE their username, delete their account and leave it at that.
  • IF the content really needs to be removed then yes run the SPAM cleaner before deleting their account - but also be mindful that they may have been quoted in threads or mentioned in profile posts.
Hope this helps,