WordPress.org

Forums

How to autoclose user accounts after 24 hours (5 posts)

  1. cmunns
    Member
    Posted 4 years ago #

    Hello,

    How might I be able to allow users to create a site on a multisite subdirectory, then autoclose these accounts after a pre-determined amount of time?

    Thanks for the help.

  2. Person
    Member
    Posted 4 years ago #

    What do you mean by 'close' the accounts? You want to lock them out from ever being able to access their blogs after 24 hours? Or are you looking to have the browser session & cookie removed after 24 hours?

    Better yet, why do you want to do this?

  3. cmunns
    Member
    Posted 4 years ago #

    It's for testing purposes, it doesn't have to be 24 hours but I don't want to overload the server so maybe somehow deleting them after a certain amount of inactivity would be better.

    ( I just don't want the number of users to be insanely high because of temporary accounts )

  4. Person
    Member
    Posted 4 years ago #

    Oh, ok. What you're looking for is to remove inactive accounts. I wouldn't suggest removing users since a user might have more than one blog on your network.

    The only thing I could find was this script: http://borism.net/2008/12/31/deleting-inactive-wordpressmu-blogs/ (which supercedes this one: http://www.ringofblogs.com/2008/06/10/wpmu-cleanup-script-to-delete-unused-blogs/), but it's incomplete, old and buggy, so I don't suggest actually using it. You can, however, use it as a reference point for writing your own script.

  5. cmunns
    Member
    Posted 4 years ago #

    I'll give it a crack, thanks for the resource

Topic Closed

This topic has been closed to new replies.

About this Topic