<?php
defined (
'main'
)
or
die
(
'no direct access'
);
$design
=
new
design (
'Server/War Rules'
,
'Server/War Rules'
);
$design
->header();
if
(
empty
(
$_POST
[
'step'
]) ) {
?>
<form action=
"index.php?installswrules"
method=
"POST"
>
<input type=
"hidden"
name=
"step"
value=
"2"
/>
<table width=
"100%"
class
=
"border"
border=
"0"
cellspacing=
"1"
cellpadding=
"3"
align=
"center"
>
<tr
class
=
"Chead"
>
<td colspan=
"2"
><b>Willkommen zur Installation von Server/War Rules</b></td></tr>
<td></td>
<td><input type=
"submit"
value=
"Weiter ->"
></td>
</tr>
</table>
</form>
<?php
}
elseif
(
$_POST
[
'step'
] == 2 ) {
$sql
=
'CREATE TABLE `prefix_ruless` ('
.
' `id` SMALLINT(5) UNSIGNED NOT NULL AUTO_INCREMENT , '
.
' `zahl` SMALLINT(6) DEFAULT 0 NOT NULL , '
.
' `titel` VARCHAR(200) NOT NULL , '
.
' `text` TEXT NOT NULL , '
.
' PRIMARY KEY ( `id` ) , '
.
' FULLTEXT ( `titel` , `text` ) '
.
' )'
.
' TYPE = myisam '
;
db_query(
$sql
);
$sql
=
'CREATE TABLE `prefix_rulesw` ('
.
' `id` SMALLINT(5) UNSIGNED NOT NULL AUTO_INCREMENT , '
.
' `zahl` SMALLINT(6) DEFAULT 0 NOT NULL , '
.
' `titel` VARCHAR(200) NOT NULL , '
.
' `text` TEXT NOT NULL , '
.
' PRIMARY KEY ( `id` ) , '
.
' FULLTEXT ( `titel` , `text` ) '
.
' )'
.
' TYPE = myisam'
;
db_query(
$sql
);
db_query(
"INSERT INTO `prefix_modules`(`url`,`name`,`gshow`,`ashow`,`fright`) VALUES ('ruless','Serverrules', 0, 1, 0)"
);
db_query(
"INSERT INTO `prefix_modules`(`url`,`name`,`gshow`,`ashow`,`fright`) VALUES ('rulesw','Warrules', 0, 1, 0)"
);
?>
<table width=
"100%"
class
=
"border"
border=
"0"
cellspacing=
"1"
cellpadding=
"3"
align=
"center"
>
<tr
class
=
"Chead"
>
<td colspan=
"2"
><b>Die Server/War Rules wurde erfolgreich installiert</b></td>
</tr>
<tr
class
=
"Cnorm"
>
<td colspan=
"2"
><b>Du solltest nun
die
/
include
/contents/installswrules.php löschen!</b></td>
</tr>
</table>
<?php
}
$design
->footer();
?>