FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » FUDforum » How To » How to remove users (make a process to remove users except admin)
Show: Today's Messages :: Polls :: Message Navigator
Switch to threaded view of this topic Create a new topic Submit Reply
How to remove users [message #167994] Wed, 05 December 2012 01:01
peterz   Australia
Messages: 8
Registered: March 2011
Location: melbourne
Karma: 0
Junior Member
I want to remove all old users except admin, can I just remove users from one table named fud30_users?

sql like : delete from fud30_users where login !='admin'


tried to run below script:

#!/usr/bin/php
<?php
require_once 'GLOBALS.php';
require_once './scripts/fudapi.inc.php';
$u = _fud_simple_fetch_query(0, "SELECT * FROM {$GLOBALS['DBHOST_TBL_PREFIX']}u
sers WHERE login = 'me'");
if (!empty($u->id)) fud_delete_user($u->id);
?>


got error message:

Status: 500 Internal Server Error
X-Powered-By: PHP/5.3.9
Content-type: text/html


can you help?
Thanks,

Peter





[Updated on: Thu, 06 December 2012 03:32]

Report message to a moderator

  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Problem with USENET (it.comp.java)
Next Topic: Statistics
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Sun Dec 22 02:29:52 GMT 2024

Total time taken to generate the page: 0.02611 seconds