Webmastersite.net
Register Log In

Cron job to delete members

Comments on Cron job to delete members

idaida
Beginner

Usergroup: Customer
Joined: Apr 02, 2010

Total Topics: 2
Total Comments: 2
idaida
Posted Apr 04, 2010 - 5:31 AM:

Hello,

Was wondering if this cron job would work ok. My captcha stopped working so I want to delete spam members that get past my javascript form validation.

I want to delete any members that do not have "human" typed in the field called visitor..

$db->delete('memberstable', "visitor != "human");

Thank you!
Paul
developer

Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California

Total Topics: 61
Total Comments: 7868
Paul
Posted Apr 06, 2010 - 6:02 PM:

Use single quotes inside the double quotes:
<?php // member deletion cron
$db->delete('memberstable', "visitor != 'human'");
?>

Save that as a .php file and add it in the crons area and it'll work, yes. That leaves them time to do stuff before being deleted though.

GD has been bundled with PHP for years, so I don't see how your CAPTCHA could stop working.
Search thread for
Download thread as
  • 0/5
  • 1
  • 2
  • 3
  • 4
  • 5



Sorry, you don't have permission to post posts. Log in, or register if you haven't yet.