X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=inc%2Fmodules%2Fadmin%2Fwhat-del_user.php;h=12e8a867a049f7ce56d2df1f5ea7ef5a4f53d447;hb=5b794a32b30ec5322765c89a22c4c27aece94a42;hp=502b9b594c914cfbd9d2d94cdd1b6f35242d57a1;hpb=56156f6c4392510cdbe0eb4f2ccefc23b43e2672;p=mailer.git diff --git a/inc/modules/admin/what-del_user.php b/inc/modules/admin/what-del_user.php index 502b9b594c..12e8a867a0 100644 --- a/inc/modules/admin/what-del_user.php +++ b/inc/modules/admin/what-del_user.php @@ -10,9 +10,14 @@ * -------------------------------------------------------------------- * * Kurzbeschreibung : Mitglieder loeschen * * -------------------------------------------------------------------- * - * * + * $Revision:: $ * + * $Date:: $ * + * $Tag:: 0.2.1-FINAL $ * + * $Author:: $ * + * Needs to be in all Files and every File needs "svn propset * + * svn:keywords Date Revision" (autoprobset!) at least!!!!!! * * -------------------------------------------------------------------- * - * Copyright (c) 2003 - 2008 by Roland Haeder * + * Copyright (c) 2003 - 2009 by Roland Haeder * * For more information visit: http://www.mxchange.org * * * * This program is free software; you can redistribute it and/or modify * @@ -32,58 +37,52 @@ ************************************************************************/ // Some security stuff... -if ((!defined('__SECURITY')) || (!IS_ADMIN())) { - $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php"; - require($INC); -} +if ((!defined('__SECURITY')) || (!isAdmin())) { + die(); +} // END - if // Display only title when no form was submitted -ADD_DESCR("admin", __FILE__); +addMenuDescription('admin', __FILE__); // User exists.. -if ((isset($_POST['ok'])) || ((isset($_POST['del'])) && (!empty($_POST['reason'])))) { - // Delete users account - $result_user = SQL_QUERY_ESC("SELECT userid FROM `"._MYSQL_PREFIX."_user_data` WHERE userid=%s LIMIT 1", - array(bigintval($_GET['u_id'])), __FILE__, __LINE__); - if (SQL_NUMROWS($result_user) == 1) { - // Free memory - SQL_FREERESULT($result_user); - +if ((isFormSent()) || ((isPostRequestElementSet('del')) && (isPostRequestElementSet(('reason'))))) { + // Is the account there? + if (fetchUserData(getRequestElement('userid'))) { // Delete user account - DELETE_USER_ACCOUNT(bigintval($_GET['u_id']), $_POST['reason']); - LOAD_TEMPLATE("admin_settings_saved", false, "