+++ /dev/null
-<?php
-/************************************************************************
- * MXChange v0.2.1 Start: 07/10/2004 *
- * =============== Last change: 07/10/2004 *
- * *
- * -------------------------------------------------------------------- *
- * File : what-config_register.php *
- * -------------------------------------------------------------------- *
- * Short description : Setup for the registration form *
- * -------------------------------------------------------------------- *
- * Kurzbeschreibung : Einstellungen fuer das Anmeldeformular *
- * -------------------------------------------------------------------- *
- * *
- * -------------------------------------------------------------------- *
- * Copyright (c) 2003 - 2008 by Roland Haeder *
- * For more information visit: http://www.mxchange.org *
- * *
- * This program is free software; you can redistribute it and/or modify *
- * it under the terms of the GNU General Public License as published by *
- * the Free Software Foundation; either version 2 of the License, or *
- * (at your option) any later version. *
- * *
- * This program is distributed in the hope that it will be useful, *
- * but WITHOUT ANY WARRANTY; without even the implied warranty of *
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
- * GNU General Public License for more details. *
- * *
- * You should have received a copy of the GNU General Public License *
- * along with this program; if not, write to the Free Software *
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, *
- * MA 02110-1301 USA *
- ************************************************************************/
-
-// Some security stuff...
-if ((ereg(basename(__FILE__), $_SERVER['PHP_SELF'])) || (!IS_ADMIN()))
-{
- $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
- require($INC);
-}
-
-// Add description as navigation point
-ADD_DESCR("admin", basename(__FILE__));
-
-// Do we want to save changes?
-if (isset($_POST['ok']))
-{
- foreach ($_POST['sel'] as $id=>$value)
- {
- $result = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_must_register SET field_required='%s' WHERE id=%d AND field_required != '%s' LIMIT 1",
- array($value, bigintval($id), $value),__FILE__, __LINE__);
- }
- LOAD_TEMPLATE ("admin_settings_saved", false, REGISTER_ADMIN_CHANGES_SAVED);
-}
-
-// List all register values
-$result = SQL_QUERY("SELECT id, field_name, field_required FROM "._MYSQL_PREFIX."_must_register ORDER BY id", __FILE__, __LINE__);
-$SW = 2; $OUT = "";
-while (list($id, $name, $required) = SQL_FETCHROW($result))
-{
- $eval = "\$name = ".strtoupper($name).";";
- eval($eval);
- $OUT .= "<TR>
- <TD align=\"center\" class=\"switch_sw".$SW." bottom2 right2\">".$id."</TD>
- <TD class=\"switch_sw".$SW." bottom2 right2\"> ".$name."</TD>
- <TD align=\"center\" class=\"switch_sw".$SW." bottom2 right2\">
- ".ADD_SELECTION("yn", $required, "sel[".$id."]")."
- </TD>
-</TR>\n";
- $SW = 3 - $SW;
-}
-
-// Free memory
-SQL_FREERESULT($result);
-
-// Remember rows in constant
-define('__REGISTER_ROWS', $OUT);
-
-// Load template
-LOAD_TEMPLATE("admin_config_register");
-
-//
-?>