changed angel types table layout

main
Philip Häusler 13 years ago
parent 0d37e85f34
commit 278dc8e5b0

@ -20,12 +20,12 @@ SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
-- --
CREATE TABLE IF NOT EXISTS `AngelTypes` ( CREATE TABLE IF NOT EXISTS `AngelTypes` (
`TID` int(11) NOT NULL AUTO_INCREMENT, `id` int(11) NOT NULL AUTO_INCREMENT,
`Name` varchar(25) NOT NULL DEFAULT '', `name` varchar(25) NOT NULL DEFAULT '',
`Man` text, `restricted` int(1) NOT NULL,
PRIMARY KEY (`TID`), PRIMARY KEY (`id`),
UNIQUE KEY `Name` (`Name`) UNIQUE KEY `Name` (`name`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ; ) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=8 ;
-- --
-- Daten für Tabelle `AngelTypes` -- Daten für Tabelle `AngelTypes`

@ -20,6 +20,12 @@ function guest_register() {
$comment = ""; $comment = "";
$tshirt_size = 'S'; $tshirt_size = 'S';
$password_hash = ""; $password_hash = "";
$selected_angel_types = array ();
$angel_types_source = sql_select("SELECT * FROM `AngelTypes` ORDER BY `name`");
$angel_types = array ();
foreach ($angel_types_source as $angel_type)
$angel_types[$angel_type['id']] = $angel_type['name'] . ($angel_type['restricted'] ? " (restricted)" : "");
if (isset ($_REQUEST['submit'])) { if (isset ($_REQUEST['submit'])) {
$ok = true; $ok = true;

Loading…
Cancel
Save