Pomoc pls moc pls

Programovacie jazyky, rady, poradňa...
eror
Medium Star
Medium Star
Príspevky: 457
Registrovaný: 16 nov 2008, 14:19
Bydlisko: GA

Pomoc pls moc pls

Príspevok od používateľa eror »

Kód: Vybrať všetko

<form action="" method="post">
<b><FONT COLOR='BLACK'>Rcon password:<br></FONT>&nbsp;&nbsp;</b>
<input name="cmd" type="password">
<br>

<form action="" method="post">
<b><FONT COLOR='BLACK'>Názov servera:<br></FONT>&nbsp;&nbsp;</b>
<input name="cmd1">
<br>

<form action="" method="post">
<b><FONT COLOR='BLACK'>gamemod:<br></FONT>&nbsp;&nbsp;</b>
<input name="cmd2">
<br>

<form action="" method="post">
<b><FONT COLOR='BLACK'>filterscipts:<br></FONT>&nbsp;&nbsp;</b>
<input name="cmd3">
<br>

<form action="" method="post">
<b><FONT COLOR='BLACK'>web stránka:<br></FONT>&nbsp;&nbsp;</b>
<input name="cmd4">
<br>
<form action="" method="post">
<b><FONT COLOR='BLACK'>heslo:<br></FONT>&nbsp;&nbsp;</b>
<input name="cmd5">
<br>

<?php
$lines = file("svr/server.cfg");
if(empty($lines)) $lines[0] = PHP_EOL;
$lines[0] = "echo Executing Server Config...".PHP_EOL;
file_put_contents('svr/server.cfg',$lines);

$lines = file("svr/server.cfg");
if(empty($lines)) $lines[0] = PHP_EOL;
$lines[1] = "lanmode 0".PHP_EOL;
file_put_contents('svr/server.cfg',$lines);

$lines = file("svr/server.cfg");
if(empty($lines)) $lines[0] = PHP_EOL;
$lines[2] = "rcon_password $_POST[cmd]".PHP_EOL;
file_put_contents('svr/server.cfg',$lines);

$lines = file("svr/server.cfg");
if(empty($lines)) $lines[0] = PHP_EOL;
$lines[3] = "maxplayers 50".PHP_EOL;
file_put_contents('svr/server.cfg',$lines);

$lines = file("svr/server.cfg");
if(empty($lines)) $lines[0] = PHP_EOL;
$lines[4] = "port 7777".PHP_EOL;
file_put_contents('svr/server.cfg',$lines);

$lines = file("svr/server.cfg");
if(empty($lines)) $lines[0] = PHP_EOL;
$lines[5] = "hostname $_POST[cmd1]".PHP_EOL;
file_put_contents('svr/server.cfg',$lines);

$lines = file("svr/server.cfg");
if(empty($lines)) $lines[0] = PHP_EOL;
$lines[6] = "gamemode0 $_POST[cmd2]".PHP_EOL;
file_put_contents('svr/server.cfg',$lines);

$lines = file("svr/server.cfg");
if(empty($lines)) $lines[0] = PHP_EOL;
$lines[7] = "filterscripts $_POST[cmd3]".PHP_EOL;
file_put_contents('svr/server.cfg',$lines);

$lines = file("svr/server.cfg");
if(empty($lines)) $lines[0] = PHP_EOL;
$lines[8] = "announce 1".PHP_EOL;
file_put_contents('svr/server.cfg',$lines);

$lines = file("svr/server.cfg");
if(empty($lines)) $lines[0] = PHP_EOL;
$lines[9] = "query 1".PHP_EOL;
file_put_contents('svr/server.cfg',$lines);

$lines = file("svr/server.cfg");
if(empty($lines)) $lines[0] = PHP_EOL;
$lines[10] = "weburl $_POST[cmd4]".PHP_EOL;
file_put_contents('svr/server.cfg',$lines);

$lines = file("svr/server.cfg");
if(empty($lines)) $lines[0] = PHP_EOL;
$lines[11] = "anticheat 0".PHP_EOL;
file_put_contents('svr/server.cfg',$lines);

$lines = file("svr/server.cfg");
if(empty($lines)) $lines[0] = PHP_EOL;
$lines[11] = "password $_POST[cmd5]".PHP_EOL;
file_put_contents('svr/server.cfg',$lines);
?>

<input type="submit" name="ok" value="Uložiť">
</form>
Taketo daco mam ako to mam spravyt tak ze ked tam dam napr password nieco ktomu tak nech sa to zmeni v tedy a ked tam nedam nic tak sa to vymaze pls pomoc?
audiotrack
VIP
VIP
Používateľov profilový obrázok
Príspevky: 25958
Registrovaný: 09 sep 2005, 18:39
Kontaktovať používateľa:

Príspevok od používateľa audiotrack »

prečítaj si pravidla, a potom to napíš ako človek (samozrejme s normálnym názvom témy)
Zamknuté