Vanilla 1 is no longer supported or maintained. If you need a copy, you can get it here.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Options

Deleting Specific Users

BenBen
edited September 2006 in Vanilla 1.0 Help
I'd quite like to have an option, as part of the cleanup extension, to delete a specific user. Perhaps even sending an automated, "Your account has been deleted" message.
«1

Comments

  • Options
    Insensible, you can delete users who have never posted, but not ones that have because it would mess up the forum. The best thing to do is to perhaps change all their details so they cant login (maybe even change their username to deleted) but taking them out the database would fuck things up.
  • Options
    Yes, that's true. However, these user's hadn't posted before, i just only wanted to delete one of them.
  • Options
    Ahhh, i slightly misread what you wrote, apologies. This would be a useful addition i suppose.
  • Options
    MarkMark Vanilla Staff
    Should be a pretty easy extension to write. Just add a delete link on the account page for users with user-admin privs. You should add it to the extension request list.
  • Options
    That link should only appear for users that have never posted though, correct? (Unless it automatically does the scrambling i suggested instead of actually deleting them) Maybe a dropdown list of users who can be deleted properly in the cleanup extension could be useful?
  • Options
    Or a checklist?
  • Options
    MarkMark Vanilla Staff
    Yeah - it should really only be "delete user" for users that don't have any comments or discussions, and it should say something like "permaban user" if they have posted comments.
  • Options
    MarkMark Vanilla Staff
    edited September 2005
    Maybe a dropdown list of users who can be deleted properly in the cleanup extension could be useful?

    I thought about that one, but in the end I think that if you're looking to delete a particular user, you're probably going to be looking at that user's account when you decide to do it (or looking at a post with a link to his/her account). So going to the cleanup extension to get rid of someone is not as user friendly as just having a button on that user's account page.

    If, however, you're looking to make vast, sweeping deletes of users in general, the cleanup extension is the place to be.
  • Options
    Maybe if someome here has some programming skills could do an extension for this.I don't think is hard to do something like this :) because i manage to delete a specific user : >>> On my hosting server i started phpMyAdmin and from the databese i've selected the LUM_User and then Browse and it come up with the list of registered users. I've selected the user and then the inline X buton to delete it. For the moment it's a solution :) <<< I'm using Vanilla and i see it has the ability to look up for user and then come up with some option for that like: Change password, Change stylesheet ,etc.. and i'm thinking that is not so hard to make an extension to put there a Delete User option for the Master Administrator :) and when you press it to initiate a connection with the database, select the LUM_User, search for the name of the user and then remove that line from the database :) If someone here could please help us with the programming skills Sory for my poor english :P
  • Options
    The thing is, if that user has visted the forum or commented, then there are connected entries in several of the other tables as well as the user one.
    To completely remove an active user, you have to delete those as well.
  • Options
    edited September 2005
    It's seems that deleting the user in the way of my previous comment remove also the display of comments of that user :) i just verified on my forum :P I was browsing my database and i find out that the UserID from the LUM_User corespond to AuthUserID in LUM_Comment and AuthUserID in LUM_Discussion so it should easy to compile a script or something to delete those entries to.
  • Options
    yes arthos, deleting the data isnt the trouble atall, the issue is that if that user has posted anything, when that thread is viewed it will be all jumbled up and wont read properly. In the case where a user hasnt posted then deleting them entirely is fine, in other cases i still think it would be a considerably better idea to just rename them and jumble all their stuff or replace any reference to their user with a global 'deleted' user so their posts etc remain intact for people browsing the forum.
  • Options
    Maybe instead of actually deleting the files you could have a pseudo delete?
    It just hides all their comments and removes their posting rights.

    Does that make sense?
  • Options
    thats equally retarded..?
  • Options
    lechlech Chicagoland
    If you destroy the user, you must destroy all posts and threads started or added by that user. One logical way to go about doing this is having an extra row in the comments/threads tables and insert another "author" row where the name is specificly cached, there by logging what name the specific user was using at the time of the post and so on. At the moment, both user name and ID are dynamicly binded so there's no way to destroy one and keep the other unless you wish to run the mind-numbing task of tracing everything from last to first. If you truely want to hose a user, just hose their account, bleach it out, and leave it as an empty shell. That way, all your posts, threads, and overall forum stay in tact.
  • Options
    I have searched these forums, and cannot find the answer to this, even though there seems to be tens of messages on this topic. I want to DELETE A USER THAT HAS NEVER POSTED. As far as I understand, this would pose no problems to the database - and it seems, from the posts in this discussion right here, that this capability *was* something that had been planned... I'm finding that this functionality is needed, because some new users, not realising that they can change their username in their account page, register 2 or 3 times - using different login names - and then just ever use the last one. As a side note: after reading the *many* discussions on why a USER should *never* be deleted, I must admit that I was a bit puzzled by it. The sole argument, it seems, for building a system which FORBIDS administrators to delete a user is (supposedly) to protect database integrity. However, the issues concerning data integrity in relational databases - such as MySQL - have already been debated extensively, in many, many books, and the strategies and options for dealing with data deletion and table integrity are well known and documented. It is really not that big a problem. At a very *basic* level, there are 2 simple options: 1) CASCADING - if record 'X' is removed from a database, any record that reffers to it is deleted. In turn, every record that reffers to these other records being deleted, will also be deleted. And so on, in a 'cascading' effect through the database. The advantage here is that *everything* that relates to the original record is certainly deleted, and thus integrity remains. The disadvantage is that you might end up deleting more than you expected. Because of this disadvantage, often databases that allow cascade-style deletion generally CONFIRM the deletion prior to doing it, and try to give the user/administrator as much information as possible about all the records in all tables that will be deleted in the process. 2) UNLINK/REPLACE - instead of deleting anything that links to the record being deleted, you can simply break the link. How this 'break' is handled depends greatly on the database, and how the dependencies on the tables were defined. If the link is a required field, instead of 'breaking' it, you may simply replace it with a 'dummy' reference (to a 'dummy' record). In such a system, there is usually a 'default' record that is setup in each table, which all 'unlinked' refferring records can link to. So, in Vanilla, the admin could be given the option to do either of the delete types: a) delete user and anything relating to user and their comments/discussions (CASCADE) b) delete user, linking their comments/discussions to a generic 'anonymous' user (REPLACE) This might not be so hard to do, and would give people the OPTION to delete if they want to, or follow the *never delete* philosophy, if they so choose. :)
  • Options
    The issue with deleteting users who've posted is not so much at a database integrity level, moreso at a user interface integrity level. If you delete everything a user has ever posted (i realise this only relates to scenario 1) then users who are reading those discussions will get mighty confused if people are referring to something that user has written. Option 2 avoids this issue fairly successfully but noone's yet written an extension to cater for this. Please go ahead if you feel it's something which aught to be catered for.

    In any case (and indeed in slight contradiction to what i've just said - i found the extension afterwards), I assume you've seen this?
  • Options
    @Minisweeper: thank you for your (very quick! and) informative reply. I would certainly love to tackle writing an extension for Vanilla, but I'm affraid my PHP skills are very, very basic. What would be the procedure to suggest this to someone more capable? - just add a discussion under "Add-On Requests" ? Thank you also for the link to the Delete User Add-On. I see that it was last updated in early July. Is this safe to use with Vanilla 1.0.1? - ie., for my purposes of deleting users who have never posted, at least?! Many, many thanks in advance for any further hints!
  • Options
    you could check how you decline a membership. It is deleting a user (applicant), and check that he never post anything (if i remember well)
  • Options
    @Dinoboff: many thanks for the hint - simply 'declining the membership' seems to be enough to do the trick! :) Many thanks!
This discussion has been closed.