/* if($_SERVER['HTTP_HOST'] != 'www.atari.org.pl') {
header("HTTP/1.1 301 Moved Permanently");
header("Location: http://www.atari.org.pl".$_SERVER['REQUEST_URI']);
header("Connection: close");
exit;
}
/*
File catalogue & uploader 0.1
(c) dely / taquart 2003
GPL
*/
// SQL.conf :)
$host = "localhost";
$username = "dely";
$pass = "uRunpXCBJ69dQ4ZX";
$base = "dely";
$table = "xxx_pliki";
// main
$sec = $_GET['sec'];
$cat = $_GET['cat'];
$letter = $_GET['letter'];
switch ($sec)
{
case 'add':
include "punbb.php";
include ('header-szeroki.inc');
$autor=$pun_user['username'];
if ($autor && ($autor=="dely" || $autor=="lewiS" || $autor=="tebe" || $autor=="elkabato" || $autor=="mikey" || $autor=="Piguła/Shpoon" || $autor=="Dracon" || $autor=="miker" || $autor=="sun" || $autor=="macgyver" || $autor=="nosty" || $autor=="xan" || $autor=="gRzEnIu"))
{
echo ("
\n");
echo (" pliki >> scena / emulacja / uzytki / gry / wyszukiwarka plików
\n");
echo ("
\n");
}
else
{
echo ("BRAK DOSTEPU !!!
Nie jestes uprawniony do ogladania tej strony. Poza tym czemu grzebiesz i szukasz tam gdzie nie potrzeba ? Twoje IP zostalo zalogowane i mozesz sie spodziewac przykrych konsekwencji!");
}
include ('footer-szeroki.inc');
break;
case 'edit':
$id = $_GET['id'];
include "punbb.php";
include ('header-szeroki.inc');
$connection = mysqli_connect("$host","$username","$pass");
$db = mysqli_select_db($connection,"$base");
$sql = "SELECT * FROM $table WHERE id = '$id'";
$sql_result = mysqli_query($connection,$sql);
$sql_result = mysqli_query($connection,$sql);
$kolumna = mysqli_fetch_array($sql_result);
$title = $kolumna["title"];
$id = $kolumna["id"];
$description = $kolumna["description"];
$category = $kolumna["category"];
$uploader = $kolumna["uploader"];
$autor=$pun_user['username'];
$link = $kolumna["link"];
if ($autor && ($autor=="dely" || $autor=="lewiS" || $autor=="tebe" || $autor=="elkabato" || $autor=="mikey" || $autor=="Dracon" || $autor=="miker" || $autor=="angree" || $autor=="sun" || $autor=="nosty" || $autor=="Cyprian_Konador" || $autor=="gRzEnIu" || $autor=="xan"))
{
echo ("
Edycja plików
\n");
echo ("W tym miejscu mozna sobie edytowac dodane pliki, jesli po dodaniu okazalo sie, ze popelnilismy jakiegos babola. Propozycje co do funkcjonalnosci wysylac do mnie. Przypominam o tym aby bardzo dokladnie sprawdzac co sie dodaje czy tez zmienia, tak abym nie musial po Was poprawiac ! Dzieki za uwage :)
\n");
echo ("Jesli chcesz zamiast edytowac plik - po prostu go skasowac to kliknij tutaj. UWAGA ! nie mozna tego cofnac !
\n");
echo ("\n");
echo (" pliki >> scena / emulacja / uzytki / gry
\n");
echo ("
\n");
}
else
{
echo ("BRAK DOSTEPU !!!
Nie jestes uprawniony do ogladania tej strony. Poza tym czemu grzebiesz i szukasz tam gdzie nie potrzeba ? Twoje IP zostalo zalogowane i mozesz sie spodziewac przykrych konsekwencji!");
}
include ('footer-szeroki.inc');
break;
case 'save_edited':
$title = $_POST['title'];
$category = $_POST['category'];
$description = $_POST['description'];
$link = $_POST['link'];
$id = $_POST['id'];
$connection = mysqli_connect("$host","$username","$pass");
$db = mysqli_select_db($connection,"$base");
$sql = "UPDATE $table SET title = '$title', category = '$category', description = '$description', link = '$link' WHERE id = '$id'";
$sql_result = mysqli_query($connection,$sql);
header ("location: pliki.php?sec=show&id=$id");
break;
case 'download':
include "punbb.php";
$id = $_GET['id'];
$autor=$userdata['username'];
if ($autor=="Anonymous")
{
include ('header.inc');
echo "
Niestety nie jestes zalogowany, nie mozesz wiec sciagac plików. Jesli masz konto na forum mozesz sie zalogowac. Natomiast jesli jeszcze nie masz konta - spróbuj je zalozyc.
";
include ('footer-szeroki.inc');
die;
}
$connection = mysqli_connect("$host","$username","$pass");
$db = mysqli_select_db($connection,"$base");
$sql = "SELECT * FROM pliki WHERE id = '$id'";
$sql_result = mysqli_query($connection,$sql);
$kolumna = mysqli_fetch_array($sql_result);
$id = $kolumna["id"];
$link = $kolumna["link"];
$downloads = $kolumna["downloads"];
$downloads++;
$sql = "UPDATE $table SET downloads = '$downloads' WHERE id = '$id'";
$sql_result = mysqli_query($connection,$sql);
header ("Location: $link");
break;
case 'zsdcnmkl':
$id = $_GET['id'];
include ('header.inc');
$connection = mysqli_connect("$host","$username","$pass");
$db = mysqli_select_db($connection,"$base");
$sql = "SELECT * FROM pliki WHERE id = '$id'";
$sql_result = mysqli_query($connection,$sql);
$kolumna = mysqli_fetch_array($sql_result);
$pix = $kolumna["picture"];
$link = $kolumna["link"];
// $link = "/usr/home/www/dely/public_html/".$link;
// $pix = "/usr/home/www/dely/public_html/".$pix;
unlink ($pix);
unlink ($link);
echo (" Skasowano plik o id = $id
\n");
echo (" pliki >> scena / emulacja / uzytki / gry / wyszukiwarka plików
\n");
echo ("
\n");
$sql = "DELETE FROM pliki WHERE id = '$id'";
$sql_result = mysqli_query($connection,$sql);
include ('footer-szeroki.inc');
break;
case 'for_index':
$connection = mysqli_connect("$host","$username","$pass");
$db = mysqli_select_db($connection,"$base");
$literkaa = chr(rand (65,80));
$sql = "SELECT * FROM $table WHERE title LIKE '".$literkaa."%' LIMIT 0,1";
$sql_result = mysqli_query($connection,$sql);
$sql1 = "SELECT * FROM $table";
$sql_result1 = mysqli_query($connection,$sql1);
$ile2 = mysqli_num_rows($sql_result1);
$kolumna = mysqli_fetch_array($sql_result);
$title = $kolumna["title"];
$id = $kolumna["id"];
$pix = $kolumna["picture"];
$desc = $kolumna["description"];
$desc = substr($desc, 0, 350);
$desc = $desc." ...";
echo ("".$title."\n
".$desc." czytaj dalej
\n
Na obecna chwilę w bazie plików znajduje się $ile2 aplikacji.
\n");
break;
case 'save':
$category = $_POST['category'];
$description = $_POST['description'];
$title = $_POST['title'];
$uploader = $_POST['uploader'];
if ($_FILES['upload']['name'][0] != "" && $_FILES['upload']['name'][1] != "" && $category !="" && $description != "" && $title != "")
{
$size = getimagesize ($_FILES['upload']['tmp_name'][1]);
if ($size[0] > 400 || $size[1] > 400)
{
include ('header-szeroki.inc');
echo ("Obrazek jest za duzy. Maksymalne wymiary to 400x400, rozmiar obrazka wgranego przez ciebie to ".$size[0]."x".$size[1]." !");
echo ("
Popraw i zeby mi to bylo ostatni raz !
");
echo ("
");
include ('footer-szeroki.inc');
die;
}
$string = explode (".", $_FILES['upload']['name'][0]);
switch (strtolower($string[count($string)-1]))
{
case 'atr':
case 'xex':
case 'gz':
case 'zip':
case 'lzx':
case 'lha':
case 'bz2':
case 'bz':
case 'rar':
switch ($category)
{
case 'utils':
case 'games':
case 'scene':
case 'emu':
$link = "files/".$category."/".$_FILES['upload']['name'][0];
if (file_exists($link))
{
include ('header-szeroki.inc');
echo ("Plik o takiej nazwie juz istnieje !!!");
echo ("
Zmien nazwe pliku i spróbuj ponownie.");
echo ("
");
include ('footer-szeroki.inc');
die;
}
break;
default:
header ("Location: pliki.php?sec=browse");
break;
}
break;
default:
include ('header-szeroki.inc');
echo ("
Jako download mozna wgrywac tylko pliki xex, atr, lha, gz, lzx, rar oraz zip");
echo ("
Twoj plik ma rozszerzenie: ".strtolower($string[count($string)-1]));
echo ("
");
include ('footer-szeroki.inc');
die;
}
$pstring = explode (".", $_FILES['upload']['name'][1]);
switch (strtolower($pstring[count($pstring)-1]))
{
case 'jpg':
case 'jpeg':
case 'gif':
case 'png':
$plink = "files/pix/".$_FILES['upload']['name'][1];
if (!file_exists($plink))
{
move_uploaded_file ($_FILES['upload']['tmp_name'][0], $link);
move_uploaded_file ($_FILES['upload']['tmp_name'][1], $plink);
}
else
{
include ('header-szeroki.inc');
echo ("
Obrazek o takiej nazwie juz istnieje !!!");
echo ("
Zmien nazwe pliku i spróbuj ponownie.");
echo ("
");
include ('footer-szeroki.inc');
die;
}
break;
default:
include ('header-szeroki.inc');
echo ("
Jako obrazki mozna wgrywac tylko pliki jpg, png oraz gif");
echo ("
Twoj plik ma rozszerzenie: ".strtolower($string[count($string)-1]));
echo ("
Popraw i zeby mi to bylo ostatni raz !
");
echo ("
");
include ('footer-szeroki.inc');
die;
}
$connection = mysqli_connect("$host","$username","$pass");
$db = mysqli_select_db($connection,"$base");
$sql = "INSERT INTO $table (title, link, uploader, description, category, picture) VALUES ('$title', '$link', '$uploader', '$description', '$category', '$plink')";
$sql_result = mysqli_query($connection,$sql);
mysqli_close($connection);
}
else
{
include ('header-szeroki.inc');
echo ("Nie wypelniono wszystkich pol !");
echo ("
Popraw i zeby mi to bylo ostatni raz !
");
echo ("
");
include ('footer-szeroki.inc');
die;
}
include ('header-szeroki.inc');
echo ("Poprawnie wgrano plik ".$_FILES['upload']['name'][0].", rozmiar pliku: ".$_FILES['upload']['size'][0]." bajtów");
echo ("
Obrazek poprawny (".$_FILES['upload']['name'][1]."), rozmiar pliku: ".$_FILES['upload']['size'][1]." bajtów, rozmiar ".$size[0]."x".$size[1]);
echo ("
powrót");
echo ("
");
include ('footer-szeroki.inc');
break;
case 'browse':
switch ($cat) {
case 'utils':
case 'scene':
case 'games':
case 'emu':
$connection = mysqli_connect("$host","$username","$pass");
$db = mysqli_select_db($connection,"$base");
if (!$letter && $cat == "games") {
$letter = chr(rand(65,90));
}
elseif ($letter == "all") {
$letter = "";
}
$sql = "SELECT * FROM $table WHERE category = '$cat' AND title LIKE '".$letter."%' ORDER BY title ASC";
$sql_result = mysqli_query($connection,$sql);
$cnt = 0;
include ('includes/header.tpl');
echo("
Pliki
"
);
if ($cat == "games") {
echo ("
");
for ($i=65;$i<91;$i++){
echo("".chr($i)." ");
}
echo ("
");
}
echo ("
");
//echo ("
");
include('includes/second.tpl');
$table = "twoliner";
$dataa = date ("H:i");
$autor = $pun_user['username'];
$connection = mysqli_connect("$host","$username","$pass");
$db = mysqli_select_db($connection,"$base");
$sqlx = "SELECT * FROM $table";
$sql_resultx = mysqli_query($connection,$sqlx);
$ileonlinerow = mysqli_num_rows($sql_resultx);
$sql = "SELECT * FROM $table ORDER BY id DESC LIMIT 0,10";
$sql_result = mysqli_query($connection,$sql);
echo ("\n");
while ($kolumna = mysqli_fetch_array($sql_result)) {
$tresc = $kolumna["content"];
$kto = $kolumna["author"];
$data = $kolumna["date"];
$sql_bb = "SELECT id FROM punbbbusers WHERE username = '$kto'";
$sqlppp = mysqli_query($connection,$sql_bb);
$numerek = mysqli_fetch_array($sqlppp);
echo("- $kto, $data
$tresc \n");
}
echo ("
\n");
include('includes/third.tpl');
$connection = mysqli_connect("$host","$username","$pass");
$db = mysqli_select_db($connection,"$base");
$autor=$pun_user['username'];
$sql = "SELECT * FROM `punbbbtopics` ORDER BY ID DESC LIMIT 0, 10";
$sql_result = mysqli_query($connection,$sql);
while ($kolumna = mysqli_fetch_array($sql_result)) {
$id = $kolumna["id"]; $tytul = $kolumna["subject"];
if (strlen($tytul) > 26) $tytul = substr($tytul, 0,30)."...";
$poster = $kolumna["poster"]; $num_replies = $kolumna["num_replies"]; $last_poster=$kolumna['last_poster'];
if ($kolumna["question"] == "") $wrd = "viewtopic";
else $wrd = "viewpoll";
$sqlppp = mysqli_query($connection,$sql_bb);
$numerek = @mysqli_fetch_array($sqlppp);
echo("$tytul
autor: $poster, odpowiedzi: $num_replies
ostatnia odpowiedź: $last_poster\n");
}
@include('includes/fourth.tpl');
$connection = mysqli_connect("$host","$username","$pass");
$db = mysqli_select_db($connection,"$base");
$sql = "SELECT tagi FROM `news_n`";
$sql_result = mysqli_query($connection,$sql);
while ($kolumna = mysqli_fetch_array($sql_result)) {
$tags = $kolumna['tagi'];
$t2 = explode(",", $tags);
for ($a=0;$a 1) $tagtable[]=$t2[$a];
}
}
$taguniq = array_keys(array_flip($tagtable));
//$tagtable = sort($tagtable);
//$taguniq = sort($taguniq);
$sum = count($tagtable);
echo $abc;
for ($id=0; $id".$taguniq[$id]."\n");
}
include('includes/footer.tpl');
break;
default:
$connection = mysqli_connect("$host","$username","$pass");
$db = mysqli_select_db($connection,"$base");
include ('header-szeroki.inc');
echo ("\n");
echo (" \n");
echo (" Wybierz kategorię: | \n");
echo ("
\n");
echo (" \n");
echo (" Ponizej znajdują sie kategorie plików, z których mozesz wybierac. Przy kazdej z nich znajduja sie krótkie opisy ostatnio dodanych plików w kazdej z kategorii. Aby przejśc do wybranej podgrupy wystarczy kliknąc jej nazwe, aby przejśc do ostatnio dodanego pliku - kliknij jego nazwe. | \n");
echo ("
\n");
echo (" \n");
echo ("
| \n");
echo ("
\n");
echo (" \n");
$sql = "SELECT * FROM $table WHERE category = 'utils' ORDER BY id DESC";
$sql_result = mysqli_query($connection,$sql);
$ile = mysqli_num_rows($sql_result);
echo (" Programy uzytkowe Aktualna liczba pozycji: $ile, trzy ostatnio dodane: ");
for ($i=0; $i<3; $i++)
{
$kolumna = mysqli_fetch_array($sql_result);
$title = $kolumna["title"];
$id = $kolumna["id"];
$pix = $kolumna["picture"];
$desc = $kolumna["description"];
$desc = substr($desc, 0, 160);
$desc = $desc." ...";
echo ("".$title." ");
}
echo (" ");
echo (" | \n");
echo (" Popularne ");
echo (" Ponizej znajduja sie najczesciej pobierane pliki z naszej bazy. Po kliknieciu w nazwe mozna zajrzec co to za plik ;) \n");
$sql = "SELECT * FROM $table ORDER BY downloads DESC";
$sql_result = mysqli_query($connection,$sql);
for ($p=0; $p<10; $p++)
{
$kolumna = mysqli_fetch_array($sql_result);
$title1 = $kolumna["title"];
$id1 = $kolumna["id"];
if (strlen($title1) > 21) $title1 = substr($title1, 0,21)."...";
$downloads1 = $kolumna["downloads"];
$q = $p+1;
echo ("".$q." | $title1 | $downloads1 | ");
}
echo (" ");
echo (" Lista nastepna zawiera najczesciej wyswietlane pliki. Klikamy na nazwe aby obejrzec co to za plik ;) \n");
$sql = "SELECT * FROM $table ORDER BY hits DESC";
$sql_result = mysqli_query($connection,$sql);
for ($p=0; $p<10; $p++)
{
$kolumna = mysqli_fetch_array($sql_result);
$title1 = $kolumna["title"];
$id1 = $kolumna["id"];
if (strlen($title1) > 21) $title1 = substr($title1, 0,21)."...";
$downloads1 = $kolumna["hits"];
$q = $p+1;
echo ("".$q." | $title1 | $downloads1 | ");
}
echo (" | ");
echo ("
\n");
echo (" \n");
echo (" ".$title."\n");
echo (" ".$desc." \n");
echo (" | \n");
echo ("
\n");
echo (" \n");
echo ("
| \n");
echo ("
\n");
echo (" ");
$sql = "SELECT * FROM $table WHERE category = 'emu' ORDER BY id DESC";
$sql_result = mysqli_query($connection,$sql);
$ile = mysqli_num_rows($sql_result);
echo (" Emulatory Aktualna liczba pozycji: $ile, trzy ostatnio dodane: ");
for ($i=0; $i<3; $i++)
{
$kolumna = mysqli_fetch_array($sql_result);
$title = $kolumna["title"];
$id = $kolumna["id"];
$pix = $kolumna["picture"];
$desc = $kolumna["description"];
$desc = substr($desc, 0, 160);
$desc = $desc." ...";
echo ("".$title." ");
}
echo (" ");
echo (" | \n");
echo ("
\n");
echo (" ");
echo (" ".$title."\n");
echo (" ".$desc." \n");
echo (" | ");
echo ("
");
echo (" ");
echo ("
| ");
echo ("
");
echo (" ");
$sql = "SELECT * FROM $table WHERE category = 'games' ORDER BY id DESC";
$sql_result = mysqli_query($connection,$sql);
$ile = mysqli_num_rows($sql_result);
echo (" Gry Aktualna liczba pozycji: $ile, trzy ostatnio dodane: ");
for ($i=0; $i<3; $i++)
{
$kolumna = mysqli_fetch_array($sql_result);
$title = $kolumna["title"];
$id = $kolumna["id"];
$pix = $kolumna["picture"];
$desc = $kolumna["description"];
$desc = substr($desc, 0, 160);
$desc = $desc." ...";
echo ("".$title." ");
}
echo (" ");
echo (" | \n");
echo ("
\n");
echo (" ");
echo (" ".$title."\n");
echo (" ".$desc." \n");
echo (" | ");
echo ("
");
echo (" ");
echo ("
| ");
echo ("
");
echo (" ");
$sql = "SELECT * FROM $table WHERE category = 'scene' ORDER BY id DESC";
$sql_result = mysqli_query($connection,$sql);
$ile = mysqli_num_rows($sql_result);
echo (" Scena Aktualna liczba pozycji: $ile, trzy ostatnio dodane: ");
for ($i=0; $i<3; $i++)
{
$kolumna = mysqli_fetch_array($sql_result);
$title = $kolumna["title"];
$id = $kolumna["id"];
$pix = $kolumna["picture"];
$desc = $kolumna["description"];
$desc = substr($desc, 0, 160);
$desc = $desc." ...";
echo ("".$title." ");
}
echo (" ");
echo (" | \n");
echo ("
\n");
echo (" ");
echo (" ".$title."\n");
echo (" ".$desc." \n");
echo (" | ");
echo ("
");
echo (" ");
echo ("
| ");
echo ("
");
$sql = "SELECT uploader FROM $table WHERE uploader LIKE 'Te%'";
$sql_result = mysqli_query($connection,$sql);
$iletebe = mysqli_num_rows($sql_result);
$sql = "SELECT uploader FROM $table WHERE uploader LIKE 'de%'";
$sql_result = mysqli_query($connection,$sql);
$iledely = mysqli_num_rows($sql_result);
$sql = "SELECT uploader FROM $table WHERE uploader LIKE 'le%'";
$sql_result = mysqli_query($connection,$sql);
$ilelewis = mysqli_num_rows($sql_result);
$sql = "SELECT uploader FROM $table WHERE uploader LIKE 'no%'";
$sql_result = mysqli_query($connection,$sql);
$ilenosty = mysqli_num_rows($sql_result);
$sql = "SELECT uploader FROM $table WHERE uploader LIKE 'Mikey%'";
$sql_result = mysqli_query($connection,$sql);
$ilemikey = mysqli_num_rows($sql_result);
$sql = "SELECT uploader FROM $table WHERE uploader LIKE 'el%'";
$sql_result = mysqli_query($connection,$sql);
$ileelkabato = mysqli_num_rows($sql_result);
$sql = "SELECT uploader FROM $table WHERE uploader LIKE 'Dr%'";
$sql_result = mysqli_query($connection,$sql);
$iledracon = mysqli_num_rows($sql_result);
$sql = "SELECT uploader FROM $table WHERE uploader LIKE 'su%'";
$sql_result = mysqli_query($connection,$sql);
$ilesun = mysqli_num_rows($sql_result);
$sql = "SELECT uploader FROM $table WHERE uploader LIKE 'an%'";
$sql_result = mysqli_query($connection,$sql);
$ileangree = mysqli_num_rows($sql_result);
$sql = "SELECT uploader FROM $table WHERE uploader LIKE 'gR%'";
$sql_result = mysqli_query($connection,$sql);
$ilegrzeniu = mysqli_num_rows($sql_result);
$sql = "SELECT uploader FROM $table WHERE uploader LIKE 'Miker%'";
$sql_result = mysqli_query($connection,$sql);
$ilemiker = mysqli_num_rows($sql_result);
$sql = "SELECT uploader FROM $table WHERE uploader LIKE 'Pig%'";
$sql_result = mysqli_query($connection,$sql);
$ilepigula = mysqli_num_rows($sql_result);
echo (" ");
echo (" Pliki do bazy dodaja nastepujace osoby: angree ($ileangree), dely / Taquart ($iledely), Dracon / Taquart ($iledracon), elkabato ($ileelkabato), gRzEnIu ($ilegrzeniu), lewiS / Aids ($ilelewis), Miker / AiDS / BB ($ilemiker), Mikey ($ilemikey), nosty ($ilenosty), sun ($ilesun), TeBe / Madteam ($iletebe), Piguła / Shpoon ($ilepigula). | ");
echo ("
");
echo ("
");
echo ("
");
include ('footer-szeroki.inc');
break;
}
break;
case 'search':
include ('header-szeroki.inc');
echo ("\n");
include ('footer-szeroki.inc');
break;
case 's_result':
if ($_POST['query'])
{
$connection = mysqli_connect("$host","$username","$pass");
$db = mysqli_select_db($connection,"$base");
if ($opisy != "")
{
$sql = "SELECT title, id, category FROM $table WHERE 1 AND title LIKE '%".$_POST['query']."%' OR description LIKE '%".$_POST['query']."%' ORDER by category, title ASC";
}
else
{
$sql = "SELECT title, id, category FROM $table WHERE 1 AND title LIKE '%".$_POST['query']."%' ORDER by category, title ASC";
}
$sql_result = mysqli_query($connection,$sql);
$ile = mysqli_num_rows($sql_result);
include ('header-szeroki.inc');
echo ("");
echo ("Wyniki wyszukiwania
|
");
echo ("Znaleziono $ile pasujacych do Twojego zapytania plików. Ponizej znajduja sie znalezione pliki
|
");
$cnt=0;
while ($kolumna = mysqli_fetch_array($sql_result))
{
$title = $kolumna["title"];
$id = $kolumna["id"];
$category = $kolumna["category"];
$cnt++;
echo (" ");
echo (" ".$title." :: $category | ");
echo ("
");
}
echo ("pliki >> scena / emulacja / uzytki / gry / wyszukiwarka plików |
");
echo ("
");
echo ("
");
include ('footer-szeroki.inc');
}
else
{
include ('header-szeroki.inc');
echo ("Nie wpisano nic w pole wyszukiwania !
");
echo ("Popraw i zeby mi to bylo ostatni raz !
pliki >> scena / emulacja / uzytki / gry / wyszukiwarka plików");
echo ("
");
include ('footer-szeroki.inc');
}
break;
case 'show':
$id = $_GET['id'];
include "punbb.php";
$autor=$pun_user['username'];
$connection = mysqli_connect("$host","$username","$pass");
$db = mysqli_select_db($connection,"$base");
$sql = "SELECT * FROM $table WHERE id = '$id'";
$sql_result = mysqli_query($connection,$sql);
include ('includes/header.tpl');
echo ("