boris.slipgate.org
"I am a geek. I hate to be a geek, but I'm too weak to overcome my fear"

news
about me
my computers
irc
doom
mapgen

www.ppopn.net //----------------------------------------------------- // Copyrightrichtlinien (es gilt das Copyleft der GPL): // www.gnu.org/copyleft/gpl.html //----------------------------------------------------- ##################### $conf = "pnews/config.php"; ##################### // Config Auslesen $config = file($conf); $config = explode("|--|",$config[1]); $nps = $config[1]; $code = $config[2]; $head_links = $config[4]; $pn_db = $config[5]; $pn_images = $config[6]; $pn_temp = $config[7]; $pn_lang = $config[8]; $dateiname = $config[9]; $admin_file = $config[10]; $prefix = $config[11]; $fontface = $config[12]; $fontsize = $config[13]; $sml_font = $fontsize - 1; $lrg_font = $fontsize + 1; $tbsize = "$config[14]%"; $tbcolor1 = $config[15]; $tbcolor2 = $config[16]; $site_name = $config[18]; $servertime = ($config[20]*60)*60; $news_submit= $config[21]; $submit_value = $config[22]; $rel_aus = $config[23]; $email_submit = $config[24]; $max_b = $line[25]; $highlight = $config[26]; $foot_links = $config[27]; $quote_hr_color = $config[28]; $smilies_db = $config[29]; $java_s = $config[30]; //-- Ende //------Register Globals $GET_POST = array_merge($_GET, $_POST, $_SESSION); extract($GET_POST); //------ // Datenbank Auslesen $db = file("$pn_db/news.dat"); $db_anz = count($db); $kate = file("$pn_db/kats.dat"); $anz_kat = count($kate); $db_sub = file("$pn_db/submit.dat"); $anz_sub = count($db_sub); // Ende $seiten = $db_anz/$nps; $seiten = ceil($seiten); // Dateien Includen include("$pn_lang/functions.php"); include("$pn_lang/language.php"); $sort_dropdown = sort_dropdown(); // Ende // Header $head = "$pn_temp/header.html"; $open_head = fopen($head, "r"); $head = fread($open_head, filesize($head)); $head = ereg_replace("\{admin\}","$ab",$head); $head = ereg_replace("\{news\}","$ac",$head); $head = ereg_replace("\{anz\}","$db_anz",$head); $head = ereg_replace("\{anz_aktiv\}","$anz_sub",$head); $head = ereg_replace("\{seiten\}","$seiten",$head); $head = ereg_replace("\{submit\}","$fg",$head); $head = ereg_replace("\{search\}","$ft",$head); $head = ereg_replace("\{logout\}","$gc",$head); $head = ereg_replace("\{archiv\}","$gg",$head); $head = ereg_replace("\{kategorien\}","$sort_dropdown",$head); fclose($open_head); echo $head; // Ende if($pn=='' OR $pn==view) { if($db_anz == 0) { rahmen_text("$gn
"); } else { $data = file("$pn_db/news.dat"); $data = array_reverse($data); if($sort_kat=='') { $seitenlink = seiten($seiten); $temp = zeilen($data,$db_anz); } else { $i = 0; $y = 0; while($i<$db_anz) { $news = explode("|--|",$data[$i]); if($news[8]==$sort_kat) { $data_news[$y] .= $i; $anz_news++; $y++; } $i++; } $seiten = $anz_news/$nps; $seitenlink = seiten($seiten); $temp = zeilen($data_news,$anz_news); } if($head_links==ON) { echo "$seitenlink
"; } echo $temp; if($foot_links==ON) { echo "$seitenlink
"; } } } //-- News Posten if($pn=='post') { $login = user_login($login); if($login == 'TRUE') { echo javasmilies(); $timestamp = time(); $datum = date("d.m.Y",$timestamp); $zeit = date("H:i",$timestamp); $user_db = file("$pn_db/user.dat"); $user_db = explode("|-|", $user_db[$user]); echo "
$ao
$av

$aw

$ax

 
$ay

$gd
"; echo list_smilies(); echo "more

$gf



 
$gs
 
$ha
$hb
 
$az
$ba
$bb
$bc


"; } else { rahmen_text("$aa
"); } } if($pn == 'detail') { echo javasmilies(); echo shownews($id,0,0,0,0); $fdb_db = file("$pn_db/feedback.dat"); $fdb_data = explode("<||>",$fdb_db[$id]); $news_db = file("$pn_db/news.dat"); $news_data = explode("|--|",$news_db[$id]); $anz_fdb = count($fdb_data); if($news_data[13]==Ja) { echo "
$af
"; if($fdb_data[0] == "") { echo "
$be
"; } else { $i = 0; while($i < $anz_fdb) { $icq = ''; $email = ''; $www = ''; $postnr = $i + 1; $feedback_temp = "$pn_temp/feedback.html"; $fp = fopen("$feedback_temp", "r"); $fb_temp = fread($fp, filesize($feedback_temp)); fclose($fp); $feedback = explode("<|>",$fdb_data[$i]); $datum = $feedback[5]; $zeit = $feedback[7]; $www = wwwcheck($feedback[2]); if($feedback[3] != "") { $icq = "\"$bf"; } if($feedback[1] != "") { $email = ""; } if($www != "") { $www = ""; } $fdb = $feedback[4]; $fdb_o = pcode_revert($fdb); $name = $feedback[0]; $quote = ""; if($quote_id==$i AND $quote_id != '') { $quote_text = "\[quote\]$name $gp:\[br\] \[b\]$fdb_o\[/b\]\[/quote\]"; } $fdb = smilies($fdb); $fdb = preg_replace("/\[quote\](.*)\[\/quote]/isU", "
Quote:

\\1

", $fdb); $fb = ereg_replace("\{feedback\}", "$fdb", $fb_temp); $fb = ereg_replace("\{name\}", "$name", $fb); $fb = ereg_replace("\{email\}", "$email", $fb); $fb = ereg_replace("\{www\}", "$www", $fb); $fb = ereg_replace("\{icq\}", "$icq", $fb); $fb = ereg_replace("\{datum\}", "$datum", $fb); $fb = ereg_replace("\{zeit\}", "$zeit", $fb); $fb = ereg_replace("\{nr\}", "$postnr", $fb); $fb = ereg_replace("\{quote\}", "$quote", $fb); $fb = ereg_replace("\[br\]", "
", $fb); echo $fb; $i++; } } echo ""; if($code=='pcode') { $pc_fb = "$bk $bm"; } else { $pc_fb = "$bk $bn"; } if($code=='html') { $ht_fb = "$bl $bm"; } else { $quote_text = ereg_replace("
", "\[br\]", $quote_text); $ht_fb = "$bl $bn"; } $cook = explode("...",$HTTP_COOKIE_VARS["PNewsComments"]); echo"

$af $ah
$ai
$aj
$ak
$al
$ga

$am

$gd
"; echo list_smilies(); $quote_text = stripslashes($quote_text); echo "more

$gf



$bo

$ht_fb
$pc_fb

"; } } if($pn==search) { echo "
$fp
"; if($search_string=='') { echo "
$fq
$fu


"; } else { $data = file("$pn_db/news.dat"); $data = array_reverse($data); $anz = count($data); $i = 0; $such_ergebnis = ''; while($i<$anz) { $db = explode("|--|",$data[$i]); $search = "/\b$search_string\b/i"; if($bereich==1) { $news = "$db[2] $db[12]"; } elseif($bereich==2) { $news = $db[1]; } if(preg_match($search,$news)) { $such_ergebnis .= "$i,"; } $i++; } $suche = explode(",",$such_ergebnis); $ergebnis = count($suche); $ergebnis = $ergebnis-1; $c = 0; echo "
$ergebnis $fs

"; while($c<$ergebnis) { $nr = $suche[$c]; $template = shownews($nr,1,$search,$bereich,0); echo $template; $c++; } } } if($pn==smilies) { echo "
Smilies

"; $fp = opendir("$pn_images/smilies"); echo "
"; while($datei = readdir($fp)) { if($datei == '.' OR $datei == '..') { echo ""; } else { $bild = $datei; $datei = str_replace(".gif","", $datei); echo ""; } } echo "
Code Smilie
:$datei:

P-Code

Code Ergebnis
[b]Text[/b] Text
[u]Text[/u] Text
[i]Text[/i] Text
[URL]http://url.de[/URL] http://url.de
[URL=http://url.de]Meine URL[/URL] Meine URL
[IMG]http://bild.jpg[/IMG]
[Quote]Zitat[/Quote] \"Zitat\"
"; } if($pn==archiv) { $data = file("$pn_db/news.dat"); $data = array_reverse($data); $anz = count($data); $y = $anz-1; $i = 0; echo "
Archiv "; while($i<$anz) { $news = explode("|--|",$data[$i]); echo ""; $y--; $i++; } echo "
Titel
Datum / Zeit
Autor
$news[1]
$news[3] / $news[4]
$news[0]
"; } //--- News Editieren if($pn=='editform') { echo javasmilies(); $login = user_login($login); if($login == 'TRUE') { if($fileform==submit) { $news_db="$pn_db/submit.dat"; } else { $news_db = "$pn_db/news.dat"; } $file_news = file($news_db); $news = explode("|--|", $file_news[$id]); $text = ereg_replace('"', '"', $news[2]); $text = ereg_replace("
","\r\n",$text); $more = ereg_replace('"', '"', $news[12]); $more = ereg_replace("
","\r\n",$more); $titel = ereg_replace('"', '"', $news[1]); if($news[13]==Ja) { $fdb_op_val = "checked"; } if($news[14]==ON) { $email_kom_val = "checked"; } $rell = explode("",$news[6]); $anz_rell = count($rell); $i = 0; $rel_url = ''; $rel_name = ''; while($i < $anz_rell) { $rells = explode(">rl<",$rell[$i]); if($i+1==$anz_rell) { $rel_url .= $rells[1]; $rel_name .= $rells[0]; } else { $rel_url .= "$rells[1]@@"; $rel_name .= "$rells[0]@@"; } $i++; } $kat = kategorie($news[8]); echo "
$bp$id $bq
$br

$bs

$bt

$bu

$gd
"; echo list_smilies(); echo "more

$gf



 
$gs
 
$ha
$hb
 
$bv
$bw
$bx



"; } else { rahmen_text("$aa
"); } } //---- News Löschen if($pn=='delform') { $login = user_login($login); if($login == 'TRUE') { echo "
$bz$id $ca
"; } else { rahmen_text("$aa
"); } } //---- Admin Center if($pn=='admin') { $login = user_login($login); if($login == 'TRUE') { $status = user_status($user); $user_name = user_name($user); if($cookie_on==ON) { $java = java(admin); echo $java; } echo "
$ap

$cb • "; if($status=='0') { echo "$cc • "; } echo "$cd

"; if($status!='2') { $db_sub = file("$pn_db/submit.dat"); $anz_sub = count($db_sub); echo "
"; if($anz_sub!=0) { echo "

$gz

"; $i = 0; while($i<$anz_sub) { $sub_data = explode("|--|",$db_sub[$i]); echo ""; $i++; } echo "
$gw

$gx

$he

$gy

$sub_data[1]


"; } echo "

Aktive News

"; $news_a = file("$pn_db/news.dat"); $anz = count($news_a); $i = 0; $anz2 = $anz -1; while($i < $anz) { $news = explode("|--|", $news_a[$anz2]); $anz_fb = $news[5]; echo ""; $i++; $anz2--; } echo "
$ce
$cf
$cg
$ch
$news[1]
"; if($status=='0' OR $status=='1' OR $status=='2' AND $news[0]==$user_name) { echo ""; } elseif($status=='2' AND $news[0]!=$user_db[0]) { echo ""; } echo "
"; if($status=='0' OR $status == '1') { echo ""; } elseif($status=='2') { echo ""; } echo "
"; if($status=='0' OR $status == '1') { echo "$ci($anz_fb)"; } elseif($status=='2') { echo "$ci($anz_fb)"; } echo "
"; } } else { $cook = explode("...",$HTTP_COOKIE_VARS[PNews]); echo"
"; if($passwort != '') { echo ""; $username = explode("|-|", $user_db[$user]); $betreff = "Error Login: $username[0]"; $text = $go; $timestamp = $servertime+time(); $date = date("H:i - d.m.Y",$timestamp); $text .= " @ $date"; @mail("$username[3]", $betreff, $text, "From: P-News Admin "); } echo "
$ev
$cj
$ck
$ga
$gl
$gm

"; } } //--- Feedback Auflisten if($pn=='listcomments') { $login = user_login($login); if($login == 'TRUE') {//1 $status = user_status($user); if($status!='2') {//2 echo "
$af

"; $db = file("$pn_db/feedback.dat"); $com = explode("<||>", $db[$id]); if($com[0]=='') { $anz_com = 0; } else { $anz_com = count($com); } echo "
"; $i = 0; while($i < $anz_com) { $comments = explode("<|>", $com[$i]); $postnr= $i + 1; $text = substr($comments[4], 0, 30) . " ..."; $text= strip_tags($text); echo ""; $i++; } echo "
$ey $cl $ex
$cm
$cn
$postnr
$comments[0] $text
$comments[6]


"; }//2 else { rahmen_text("$gj
"); } }//1 else { rahmen_text("$aa
"); } } //-- Feedback Löschen if($pn=='delcomment') { $login = user_login($login); if($login == 'TRUE') { rahmen_text("
$cq $name $cr

"); } else { rahmen_text("$aa
"); } } //--- Benutzer Auflisten if($pn=='member') { $login = user_login($login); if($login == 'TRUE') { echo "
$aq

$cs$cww

"; $i=0; $user_db = file("$pn_db/user.dat"); $anz_user = count($user_db); while($i<$anz_user) { $user1 = explode("|-|", $user_db[$i]); if($user1[2]==0) { $status = "$cx"; } elseif($user1[2]==1) { $status = "$cy"; } else { $status = "$cz"; } echo ""; $i++; } echo "
$ct $cu $cv $cw
$user1[0] $status

"; } else { rahmen_text("$aa
"); } } //---- Benutzer Login if($pn==memberlogin) { $login = user_login($login); if($login == 'TRUE') { $user_db = file("$pn_db/user.dat"); $user_db = explode("|-|", $user_db[$user]); echo "
$ew
$da
$dc
$dd
$de
$ga



"; } else { rahmen_text("$aa
"); } } //---- Benutzer Editieren if($pn=='editmember') { $login = user_login($login); if($login == 'TRUE') { $user_db = file("$pn_db/user.dat"); $user_db = explode("|-|", $user_db[$mid]); if($user_db[2]==0){ $sel_1 = "selected"; } if($user_db[2]==1){ $sel_2 = "selected"; } if($user_db[2]==2){ $sel_3 = "selected"; } echo "
$ar '$user_db[0]'
$df
$dg
$dh
$di


"; } else { rahmen_text("$aa
"); } } //--- Benutzer Löschen if($pn==deletemember) { $login = user_login($login); if($login == 'TRUE') { $name = user_name($mid); rahmen_text("
$dj $name $dk

"); } else { rahmen_text("$aa
"); } } //---- Passwort Ändern if($pn==memberpass) { $login = user_login($login); if($login == 'TRUE') { echo "
$as
$dl
$dm
$dn


"; } else { rahmen_text("$aa
"); } } //--- Benutzer Hinzufügen if($pn=='addmember') { $login = user_login($login); if($login != 'FALSE') { echo "
$at
$do
$dp
$dq
$dqq
$dr


"; } else { rahmen_text("$aa
"); } } if($pn==aktivnews) { $login = user_login($login); if($login == 'TRUE') { $template = shownews($id,0,0,0,1); echo "$template

"; } else { rahmen_text("$aa
"); } } if($pn==submit) { echo javasmilies(); if($news_submit=="ON") { $timestamp = $servertime+time(); $datum = date("d.m.Y",$timestamp); $zeit = date("H:i",$timestamp); $user_db = file("$pn_db/user.dat"); $user_db = explode("|-|", $user_db[$user]); echo "
$fh
$fj

$fi

$aw

$ax

$ay

$gd
"; echo list_smilies(); echo "more

$gf



 
$gs
 
$az
$ba
$bb
$bc

$bd

"; } else { rahmen_text("$fm"); } } if($pn==logout) { $java = java(logout); echo "$java"; rahmen_text("$gk
"); } if($pn=='del_inaktivnews') { $login = user_login($login); if($login == 'TRUE') { echo "
$bz$id $ca
"; } else { rahmen_text("$aa
"); } } //-------- Footer --------------------- $foot = "$pn_temp/footer.html"; $open_foot = fopen($foot, "r"); $foot = fread($open_foot, filesize($foot)); $foot = ereg_replace("\{admin\}","Admin",$foot); $foot = ereg_replace("\{news\}","News",$foot); $foot = ereg_replace("\{anz\}","$anz2",$foot); $foot = ereg_replace("\{seiten\}","$seiten",$foot); $foot = ereg_replace("\{submit\}","$fg",$foot); $foot = ereg_replace("\{search\}","$ft",$foot); $foot = ereg_replace("\{anz_aktiv\}","$anz_unac",$foot); $foot = ereg_replace("\{logout\}","$gc",$foot); $foot = ereg_replace("\{archiv\}","$gg",$foot); $head = ereg_replace("\{kategorien\}","$sort_dropdown",$head); fclose($open_foot); $version = "1.16"; $cp = "
powered by P-News $version
"; echo $foot; echo $cp; ?>





hosted on slipgate.org | powered by PHP | written using 1st page 2000
all content © 2002, 2003 by boris

PHP Valid HTML 4.0! Valid CSS!