![]() |
Ed:
A couple of things: Shouldn't it be: (joindate>=$datecut AND posts<=$joinpostsremove) instead of: (joindate<=$datecut AND posts<=$joinpostsremove) if you are trying to remove those memberships that are older than the number of days that your wanting to take out? I noticed that the } else { line doesn't work. If it takes out memberships it lists them like it should but if it doesn't find anything that matches the criteria it should give you the "No Members match....." line and it doesn't. Also, the reason that I asked about the time stamp thing is because my own joindate is listed as 867992400. I have been on our forum for 1122 days. If you multiply this by the 86,400 you get 96940800. Shouldn't these be the same? Don't you just love it when a newbie asks all kinds of questions like this? Thanks, Parker |
Quote:
Quote:
I did the math, but now that I look at it, it didn't generate that number. I think my unix timestamp info may be wrong. I guess it's not 1970. Just trust me with what I'm saying here :D Now, next post will update the code a little... |
Actually, I just made a mistake in my math, so now it works (forgot to subtract 1122)
(365 * 30) + 212 - 1122 = 10040 days since Jan 1, 1970 10,040 * 86,400 = 867456000 seconds since Jan 1, 1970 867456000 867992400 The small difference is because I didn't take into account for leap years. Ok, did that - not NEXT post will update code. |
Untested, and I only changed one line of code, but I think it should work now :)
Please note that if you type in "0" in days and like "1000000" in posts, it will probably delete ALL your users - admins included. There is no error checking or usergroup checking! (Although that's pretty simple) If this works, let me know and I'll add the checks! Code:
if ($action=="joindates") { |
Ed:
I really appreciate all your hard work but it isn't working right. I signed up today and it took me out because I had zero messages. And I set the number of days as 730 and the message count as zero. Parker |
Hmm... lemme go play around with this on my test board.
|
Ed:
Never mind. It worked. It took me out because I didn't have a sign up date. Ok this working now how about those checks that you were talking about. Or is it a humbug? :) Parker |
Ok,
This is what I have so far. In admin/index.php look for: <p><b>Threads</b><br> <a href="thread.php?action=prune">Prune</a><br> <a href="thread.php?action=move">Move</a><br> and below this add: <a href="thread.php?action=remove">Remove</a><br> <a href="thread.php?action=joindates">Join Date</a></p> Then in thread.php look for: Code:
// ###################### Start move by user selected ####################### Code:
// ###################### Start Remove by Account Date ####################### Be sure to back up your original files before using this. I am really new at this stuff and I would use any of this with caution. It worked ok on my test board. Ed: If there is anything that you think should be added please feel free to add what you think is necessary. Parker [Edited by Parker Clack on 08-02-2000 at 02:02 AM] |
Can you add a control panel options to delete all users that have not posted anything since X day (using the "last post" from their profile)
|
Thanks for this :-) it has saved me a lot of time
|
All times are GMT. The time now is 03:28 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|