<tr class="standard"> <td align="center" class="standard"> <a href="#" onclick="status(' . ($map['end'] / 500 - 1) . ', 5);">Kriegsgegner</a> </td> </tr> <tr class="standard"> <td align="center" class="standard"> <a href="#" onclick="status(' . ($map['end'] / 500 - 1) . ', 6);">Trümmerfelder</a> </td> </tr> </table> </td> </tr> </table>'; $file = fopen($path, 'w'); fputs($file, $karte); fclose($file); $karte = str_replace('SID', SID, $karte); // $karte = str_replace('%update%',countdown(4*3600),$karte); $content .= $karte; mysql_query("UPDATE `user` SET `karte` = '" . date('U') . "' WHERE `omni` = '" . $_SESSION['user']['omni'] . "' LIMIT 1 ;"); } else { $file = @fopen($path, 'r'); $size = filesize($path); $karte = fread($file, $size); $karte = str_replace('SID', SID, $karte); // $karte = str_replace('%update%',countdown(($time['karte']+(3600))-date('U')),$karte); $content .= $karte; } $content = tag2value("onload", '', $content); echo $content . template('footer');
<tr> <td align="right"> Kosten durch Ankauf </td> <td align="right"> <div id="gold_minus">0.00 Gold</div> </td> </tr> <tr> <td align="right"> <b>Endsumme</b> </td> <td align="right"> <b><div id="endsumme">0.00 Gold</div></b> </td> <td> </tr> </table> <br /> <input type="submit" name="bestellen" value="bestellen" /> </form> <br /> </td></tr></table><br />'; } $content .= '<img src="eisenstats.png" alt="stats" /><br /><br /> <img src="titanstats.png" alt="stats" /><br /><br /> <img src="oelstats.png" alt="stats" /><br /><br /> <img src="uranstats.png" alt="stats" /><br />'; // generierte seite ausgeben $content = tag2value('onload', $onload, $content); echo $content . '<br />' . template('footer');
} else { $content = showcards() . "<br /><b>Derzeitige Punkte: " . score() . '</b><br /><a href="?action=hit&' . SID . '">hit</a> / <a href="?action=stand&' . SID . '">stand</a>'; } $content = str_replace("%content%", $content, template1()); $content = str_replace("%status%", $_SESSION['game'], $content); $content = str_replace("%credits%", number_format($ressis['display_gold'], 0, '', '.'), $content); $content = str_replace("%bet%", $_SESSION['bet'], $content); mysql_query("UPDATE `ressis` SET `gold` = '" . $_SESSION['credit'] . "' WHERE `omni` = '" . $_SESSION['user']['omni'] . "' LIMIT 1;"); $ressis = ressistand($_SESSION['user']['omni']); // get playerinfo template and replace tags $status = template('playerinfo'); $status = tag2value('name', $_SESSION['user']['name'], $status); $status = tag2value('base', $_SESSION['user']['base'], $status); $status = tag2value('ubl', $_SESSION['user']['omni'], $status); $status = tag2value('points', $_SESSION['user']['points'], $status); echo tag2value('onload', $onload, template('head')) . $status . $ressis['html'] . $content . '</table>' . template('footer'); // debug // show_vars(); function template1() { // standard xhtml template $template = '<br /><br /> <table width="700px" border="1" cellspacing="0" cellpadding="0" class="standard"> <tr align="center"> <th><b>Das O-Wars Offiziers Casino</b></th> </tr> <tr style="height: 250px;"> <td valign="top" align="center"> <table width="99%" border="0" cellspacing="0" cellpadding="0"> <td width="200px" valign="top"> Einsatz: <b>%bet% Gold</b><br />
session_start(); // Basisfunktionen laden include "admin.php"; // check session logincheck(); // mit datenbank verbinden $dbh = db_connect(); if (!$_SESSION['ubl']) { die('error'); } if ($_POST['aendern'] and $_POST['panzerung']) { //mysql_query("UPDATE `gebauede` SET `basis` = '".$_POST['basis']."', `forschungsanlage` = '".$_POST['forschungsanlage']."', `fabrik` = '".$_POST['fabrik']."', `raketensilo` = '".$_POST['raketensilo']."', `nbz` = '".$_POST['nbz']."', `hangar` = '".$_POST['hangar']."', `fahrwege` = '".$_POST['fahrwege']."', `missionszentrum` = '".$_POST['missionszentrum']."', `agentenzentrum` = '".$_POST['agentenzentrum']."', `raumstation` = '".$_POST['raumstation']."', `rohstofflager` = '".$_POST['rohstofflager']."', `eisenmine` = '".$_POST['eisenmine']."', `titanmine` = '".$_POST['titanmine']."', `oelpumpe` = '".$_POST['oelpumpe']."', `uranmine` = '".$_POST['uranmine']."' WHERE `omni` = '".$_SESSION['ubl']."' LIMIT 1;"); mysql_query("UPDATE `forschungen` SET `panzerung` = '" . $_POST['panzerung'] . "',\n`reaktor` = '" . $_POST['reaktor'] . "',\n`panzerketten` = '" . $_POST['panzerketten'] . "',\n`motor` = '" . $_POST['motor'] . "',\n`feuerwaffen` = '" . $_POST['feuerwaffen'] . "',\n`raketen` = '" . $_POST['raketen'] . "',\n`sprengstoff` = '" . $_POST['sprengstoff'] . "',\n`spionage` = '" . $_POST['spionage'] . "',\n`fuehrung` = '" . $_POST['fuehrung'] . "',\n`minen` = '" . $_POST['minen'] . "',\n`cyborgtechnik` = '" . $_POST['cyborgtechnik'] . "',\n`rad` = '" . $_POST['rad'] . "' WHERE `omni` = '" . $_SESSION['ubl'] . "' LIMIT 1;"); } $temp = template('forschungen'); $fosch = mysql_fetch_array(mysql_query("SELECT * FROM `forschungen` WHERE `omni` = '" . $_SESSION['ubl'] . "';")); $temp = tag2value('panzerung', $fosch['panzerung'], $temp); $temp = tag2value('reaktor', $fosch['reaktor'], $temp); $temp = tag2value('panzerketten', $fosch['panzerketten'], $temp); $temp = tag2value('rad', $fosch['rad'], $temp); $temp = tag2value('motor', $fosch['motor'], $temp); $temp = tag2value('feuerwaffen', $fosch['feuerwaffen'], $temp); $temp = tag2value('raketen', $fosch['raketen'], $temp); $temp = tag2value('sprengstoff', $fosch['sprengstoff'], $temp); $temp = tag2value('spionage', $fosch['spionage'], $temp); $temp = tag2value('fuehrung', $fosch['fuehrung'], $temp); $temp = tag2value('minen', $fosch['minen'], $temp); $content .= template('index'); $content = tag2value('ubl', $_SESSION['ubl'], $content); $content = tag2value('content', $_SESSION['info'] . $temp, $content); echo $content;
$dbh = db_connect(); $select = "UPDATE `user` SET `timestamp` = '" . date(U) . "' WHERE `omni` = '" . $_SESSION['user']['omni'] . "' LIMIT 1 ;"; $result = mysql_query($select); $select = "SELECT * FROM `missionen` WHERE `ziel` = '" . $_SESSION[user][omni] . "' AND `type` = '1' AND `ankunft` > '" . date(U) . "' AND `parsed` != '1' ORDER BY `ankunft` DESC;"; $result = mysql_query($select); if (mysql_num_rows($result) > 0) { $menu = str_replace('logo.gif', 'attack.gif', $menu); $row = mysql_fetch_array($result); if ($row['ankunft'] - time() < 600) { $refresh = $row['ankunft'] - time(); } } $select = "SELECT * FROM `berichte` WHERE `gelesen` = 0 AND `to` = '" . $_SESSION[user][omni] . "' ORDER BY id DESC;"; $selectResult = mysql_query($select); $menu = tag2value('berichte', mysql_num_rows($selectResult), $menu); $select = "SELECT * FROM `nachrichten` WHERE `gelesen` = 0 AND `to` = '" . $_SESSION[user][omni] . "' ORDER BY id DESC;"; $selectResult = mysql_query($select); $menu = tag2value('nachrichten', mysql_num_rows($selectResult), $menu); $menu = tag2value('refresh', $refresh, $menu); $select = "SELECT karte_neu FROM `user` WHERE `omni` = " . $_SESSION['user']['omni'] . " LIMIT 1;"; $result = mysql_query($select); $row = mysql_fetch_array($result); if ($row['karte_neu'] == 1) { $karte = 'karte_neu.php'; } else { $karte = 'karte.php'; } $menu = tag2value('karte', $karte, $menu); $casino = mysql_num_rows(mysql_query("SELECT * FROM `cards` WHERE `defender` = '" . $_SESSION['user']['omni'] . "' and `status` = '1';")); $menu = tag2value('casino', $casino, $menu); echo $menu;
function outbox() { // mit datenbank verbinden $dbh = db_connect(); $result = mysql_query("SELECT * FROM `nachrichten` WHERE `from` = '" . $_SESSION['user']['omni'] . "';"); $count = mysql_num_rows($result) / 20; $count = explode('.', $count); $c = $count[0]; if ($count[1] != 0) { $c++; } if (!$_GET['page']) { $_GET['page'] = 1; } $i = 0; do { $i++; if ($_GET['page'] == $i) { $pages .= " <b>[" . $i . "]</b>"; } else { $pages .= ' <a href="nachrichten.php?' . SID . '&action=outbox&page=' . $i . '">[' . $i . ']</a>'; } } while ($c > $i); $limit = $_GET['page'] * 20 - 20 . ',' . 20; // ungelesene nachrichten $select = "SELECT * FROM `nachrichten` WHERE `from` = '" . $_SESSION[user][omni] . "' ORDER BY id DESC LIMIT " . $limit . ";"; $selectResult = mysql_query($select); $content .= template('head'); $content .= template('nachrichten_gesendet'); $piece = template('nachrichten_gesendet_piece'); do { $row = mysql_fetch_array($selectResult); if ($row) { $select = "SELECT * FROM `user` WHERE `omni` = '" . $row[to] . "';"; $selectResult2 = mysql_query($select); $row2 = mysql_fetch_array($selectResult2); $newpiece = str_replace("%date%", date("H:i d.m.y", $row[timestamp]), $piece); $newpiece = str_replace("%omni%", $row[to], $newpiece); $newpiece = str_replace("%to%", $row2[name], $newpiece); $row['gelesen'] ? $read = 'Ja' : ($read = 'Nein'); $newpiece = str_replace("%read%", $read, $newpiece); $newpiece = str_replace("%subject%", '<a href="javascript:popUp(\'nachricht_lesen.php?' . SID . '&gesendet=1&id=' . $row[id] . '\',600,\'nachricht\')">' . bbcode($row[subject]) . '</a>', $newpiece); $newpiece = str_replace("%onclick%", 'javascript:popUp(\'nachricht_lesen.php?' . SID . '&gesendet=1&id=' . $row[id] . '\',600,\'nachricht\')', $newpiece); $gelesen .= $newpiece; } } while ($row); $content = tag2value('nachrichten', $gelesen, $content); $content = tag2value('pages', $pages, $content); return $content; }
$item = tag2value('tarnung', $row['tarnung'], $item); $item = tag2value('preis', $row['preis'], $item); $item = tag2value('kaufen', '<a href="agenten.php?' . SID . '&markt=' . $row['id'] . '">kaufen</a>', $item); $items .= $item; } } while ($row); $content = tag2value('items', $items, $content); // html head setzen $top = template('head'); $top = tag2value('onload', $onload, $top); // get playerinfo template and replace tags $status = template('playerinfo'); $status = tag2value('name', $_SESSION['user']['name'], $status); $status = tag2value('base', $_SESSION['user']['base'], $status); $status = tag2value('ubl', $_SESSION['user']['omni'], $status); $status = tag2value('points', $_SESSION['user']['points'], $status); $top .= $status; // ressourcen berechnen $ressis = ressistand($_SESSION[user][omni]); $top .= $ressis['html']; // generierte seite ausgeben echo $top . $content . template('footer'); // ---------- - - - - - - - function buy_agent() { $ressis = ressistand($_SESSION['user']['omni']); $dbh = db_connect(); $select = "SELECT * FROM `gebauede` WHERE `omni` = '" . $_SESSION[user][omni] . "';"; $selectResult = mysql_query($select, $dbh); $gebaeude = mysql_fetch_array($selectResult); $select = "SELECT * FROM `agenten` WHERE `omni` = '" . $_SESSION['user']['omni'] . "';";
} if (!$_POST['tid']) { $_POST['tid'] = $_GET['tid']; } $select = "SELECT * FROM `clanforum_threads` WHERE `id` = '" . $_POST['tid'] . "';"; $result = mysql_query($select); $row = mysql_fetch_array($result); if (!$row) { die($content . '<b>Dieser Beitrag existiert nicht.</b>' . template('footer')); } elseif ($clanid != $row['cid']) { die($content . '<b>Dieser Beitrag ist einem anderen Clan.</b>' . template('footer')); } if (!$_POST['text']) { $content .= template('clanforum_reply'); $content = tag2value('topic', $row['subject'], $content); $content = tag2value('tid', $row['id'], $content); } else { mysql_query("INSERT INTO `clanforum_posts` ( `id` , `tid` , `uid` , `text` , `time` ) VALUES ( '', '" . $_POST['tid'] . "', '" . $_SESSION['user']['omni'] . "', '" . $_POST['text'] . "', '" . date("U") . "');"); mysql_query("UPDATE `clanforum_threads` SET `time` = '" . date('U') . "' WHERE `id` = '" . $_POST['tid'] . "' LIMIT 1;"); $content .= '<br />Dein Beitrag wurde hinzugefügt.<br /><a href="clanboard.php?' . SID . '">Klicke hier um zur Übersicht zurück zu kehren.</a>'; $content .= '<script language="JavaScript" type="text/javascript"> <!-- function showthread() { setTimeout(\'location.href="clanforum_showthread.php?tid=' . $_POST['tid'] . '&' . SID . '"\',2000); } showthread(); --> </script> '; } // generierte seite ausgeben
// Version: 0.0 // ////////////////////////////////// // starten der session session_name('SESSION'); session_start(); // Basisfunktionen laden include "functions.php"; // check session logincheck(); // get playerinfo template and replace tags $status = template('playerinfo'); $status = tag2value('name', $_SESSION['user']['name'], $status); $status = tag2value('base', $_SESSION['user']['base'], $status); $status = tag2value('ubl', $_SESSION['user']['omni'], $status); $status = tag2value('points', $_SESSION['user']['points'], $status); $content .= $status; // mit datenbank verbinden $dbh = db_connect(); $ressis = ressistand($_SESSION['user']['omni']); $result = mysql_query("SELECT * FROM `agenten` WHERE `omni` = '" . $_SESSION['user']['omni'] . "' AND `id` = '" . htmlentities($_GET['id']) . "';"); $row = mysql_fetch_array($result); $content .= template('agenten_mission'); //$content .= $row['name']; // html head setzen $top = template('head'); $top = tag2value('onload', $onload, $top); // ressourcen berechnen $ressis = ressistand($_SESSION[user][omni]); $top .= $ressis['html']; // generierte seite ausgeben echo $top . $content . template('footer');
die($content . '<b>Du bist in keinem Clan.</b>' . template('footer')); } $content .= template('clanforum_threads'); $piece .= template('clanforum_threads_piece'); $select = "SELECT * FROM `clanforum_threads` WHERE `cid` = '" . $clanid . "' GROUP BY `time` DESC LIMIT 50;"; $result = mysql_query($select); do { $row = mysql_fetch_array($result); $select = "SELECT * FROM `user` WHERE 1 AND `omni` = '" . $row['uid'] . "';"; $result2 = mysql_query($select); $user = mysql_fetch_array($result2); if ($row) { $select = "SELECT * FROM `clanforum_posts` WHERE `tid` = '" . $row['id'] . "' GROUP BY `id` DESC LIMIT 50;"; $result3 = mysql_query($select); $lastpost = mysql_fetch_array($result3); $select = "SELECT * FROM `user` WHERE 1 AND `omni` = '" . $lastpost['uid'] . "';"; $result4 = mysql_query($select); $lastuser = mysql_fetch_array($result4); $newpiece = tag2value('poster', $user['name'], $piece); $newpiece = tag2value('subject', '<a href="clanforum_showthread.php?tid=' . $row['id'] . '&' . SID . '">' . $row['subject'] . '</a>', $newpiece); $newpiece = tag2value('replys', mysql_num_rows($result3) - 1, $newpiece); $newpiece = tag2value('lastpost', $lastuser['name'] . '<br /><i>' . date('d.m.y - H:i', $lastpost['time']) . '</i>', $newpiece); $content .= $newpiece; } } while ($row); $content .= template('clanforum_threads_end'); if (!$newpiece) { die($content . '<b>Das Clanforum ist leer.</b>' . template('footer')); } // generierte seite ausgeben echo $content . template('footer');
if ($row) { $select = "SELECT * FROM `clans` WHERE `clanid` =" . $row['clanid'] . ";"; $result2 = mysql_query($select); $members = mysql_numrows($result2); if ($clan['clanid']) { $select = "SELECT * FROM `clan_info` WHERE `clanid` = '" . $clan['clanid'] . "';"; $result2 = mysql_query($select); $clan = mysql_fetch_array($result2); } $i++; $newpiece = tag2value('name', $row['name'], $piece); $newpiece = tag2value('rank', $i, $newpiece); $newpiece = tag2value('clanid', $row['clanid'], $newpiece); $newpiece = tag2value('members', $members, $newpiece); $newpiece = tag2value('tag', $row['tag'], $newpiece); $newpiece = tag2value('base', $row['base'], $newpiece); $newpiece = tag2value('link', '<a href="claninfo.php?' . SID . '&clan=' . $row['clanid'] . '">mehr</a>', $newpiece); $newpiece = tag2value('onclick', 'location.href=\'claninfo.php?' . SID . '&clan=' . $row['clanid'] . '\'', $newpiece); $newpiece = tag2value('points', number_format($row['points'], 0, '', '.'), $newpiece); $ranking .= $newpiece; } } while ($row); // get page html $template .= template('clanrank'); $template = tag2value('ranking', $ranking, $template); $content .= $template; $content = tag2value('pages', $pages, $content); $content = tag2value('update', date('H:i - d.m.y', filectime('temp/timestamps/points')), $content); // send page to browser $content = str_replace('%onload%', $onload, $content); echo $content . template('footer');
} $newpiece = tag2value('points', '<b>' . number_format($row['plasmapunkte'], 0, '', '.') . '</b>', $newpiece); $ranking .= $newpiece; } else { $newpiece = tag2value('name', $row['name'], $piece); $newpiece = tag2value('rank', $i, $newpiece); $newpiece = tag2value('ubl', $row['omni'], $newpiece); $newpiece = tag2value('base', $row['base'], $newpiece); if ($clan['clanid']) { $newpiece = tag2value('clan', '<a href="claninfo.php?' . SID . '&clan=' . $clan['clanid'] . '">' . $clan['tag'] . '</a>', $newpiece); } else { $newpiece = tag2value('clan', '-', $newpiece); } $newpiece = tag2value('points', number_format($row['plasmapunkte'], 0, '', '.'), $newpiece); $ranking .= $newpiece; } } } while ($row and $i < 10); $i = 0; $ranking3 = $ranking; $ranking = ''; // get page html $template .= template('sectorrank'); $template = tag2value('ranking1', $ranking1, $template); $template = tag2value('ranking2', $ranking2, $template); $template = tag2value('ranking3', $ranking3, $template); $template = tag2value('sector', number_format($_GET['sector'], 0), $template); $content .= $template; // send page to browser $content = str_replace('%onload%', $onload, $content); echo $content . template('footer');
if ($array[$a[$i]]) { $result = mysql_query("SELECT * FROM `user` WHERE `omni` = '" . $a[$i] . "' LIMIT 1;"); $row = mysql_fetch_array($result); if ($_SESSION['ubl'] != $a[$i]) { if ($array[$a[$i]] > 2000) { $red = 'class="red"'; } $multi .= '<a ' . $red . ' href="uebersicht.php?ubl=' . $a[$i] . '&' . SID . '">UBL: ' . $a[$i] . ' - ' . $row['name'] . ' [' . $array[$a[$i]] . ']</a><br />'; unset($red); } } $i++; } while ($a[$i]); } $ressis = template('ressis'); $ress = ressistand($_SESSION['ubl']); $ressis = tag2value('eisen', number_format($ress['eisen'], 0, ',', '.'), $ressis); $ressis = tag2value('titan', number_format($ress['titan'], 0, ',', '.'), $ressis); $ressis = tag2value('oel', number_format($ress['oel'], 0, ',', '.'), $ressis); $ressis = tag2value('gold', number_format($ress['gold'], 0, ',', '.'), $ressis); $ressis = tag2value('uran', number_format($ress['uran'], 0, ',', '.'), $ressis); $ressis = tag2value('chanje', number_format($ress['chanje'], 0, ',', '.'), $ressis); $sperren = template('sperren'); $content .= template('index'); $content = tag2value('ubl', $_SESSION['ubl'], $content); $content = tag2value('content', $form . $c1 . '<table cellspacing="0" border="1"><tr valign="top"><td width="254px"><b>Potentielle Multis:</b><br />' . $multi . '</td><td width="254px"><b>Ressis buchen:</b><br />' . $ressis . '</td></tr> <tr><td><b>Spieler sperren:</b>' . $sperren . '</td> <td></td> </tr> </table>', $content); echo $content;
function template($template) { // gets template and replaces template_path $path = './templates/' . $template . '.html'; $template_path = './templates/'; $file = @fopen($path, 'r'); $template = fread($file, filesize($path)); while (strstr($template, '%template_path%')) { $template = str_replace('%template_path%', $template_path, $template); } while (strstr($template, 'SID')) { $template = str_replace('SID', SID, $template); } $template = tag2value('date', date('M, d Y H:i:s'), $template); return $template; }
$status = tag2value('ubl', $_SESSION['user']['omni'], $status); $status = tag2value('points', $_SESSION['user']['points'], $status); $content .= $status; // ressourcen berechnen und ausgeben $ressis = ressistand($_SESSION[user][omni]); $content .= $ressis['html']; $content_left .= 'Clan: <b>' . $_SESSION['user']['clan'] . '<br /></b>'; $content_left .= 'Email: <b>' . $_SESSION['user']['mail'] . '<br /></b>'; $content_left .= 'Logins: <b>' . $logins . '<br /></b>'; $content_left .= 'Signatur: <b>' . $_SESSION['user']['sig'] . '<br /></b>'; $content_left .= 'Multis: <b><br />' . $multi . '<br /></b>'; } $content .= '</center><br /><br /><br /><br /> <table> <tr valign="top"> <td style="width: 230px;"> ' . $content_left . ' </td> <td style="width: 230px;"> ' . $content_center . ' </td> <td style="width: 230px;"> ' . $content_right . ' </td> </tr> </table>'; $content = tag2value('ubl', '', $content); $content .= "</form>"; // generierte seite ausgeben echo template('head') . $content . template('footer'); //show_vars();
if (!$row) { die($content . '<b>Du bist in keinem Clan.</b>' . template('footer')); } if ($_POST['text']) { $_POST['text'] = htmlspecialchars(str_replace("'", '`', $_POST['text'])); $select = "INSERT INTO `clanboard` ( `id` , `userid` , `clanid` , `date` , `text` ) VALUES ('', '" . $_SESSION['user']['omni'] . "', '" . $clanid . "', '" . date('U') . "', '" . $_POST['text'] . "');"; mysql_query($select); } $content .= '<form enctype="multipart/form-data" action="clanboard.php?' . SID . '" method="post"> <textarea name="text" style="width:680px;height:100px"></textarea><br /><input type="submit" name="submit" value="Eintragen!"></form>'; $piece .= template('clanboard'); $select = "SELECT * FROM `clanboard` WHERE `clanid` = '" . $clanid . "' GROUP BY `id` DESC LIMIT 50;"; $result = mysql_query($select); do { $row = mysql_fetch_array($result); $select = "SELECT * FROM `user` WHERE 1 AND `omni` = '" . $row['userid'] . "';"; $result2 = mysql_query($select); $user = mysql_fetch_array($result2); if ($row) { $newpiece = tag2value('name', $user['name'], $piece); $newpiece = tag2value('ubl', $row['userid'], $newpiece); $newpiece = tag2value('time', date('d.m.Y H:i', $row['date']), $newpiece); $newpiece = tag2value('text', nl2br($row['text']), $newpiece); $content .= $newpiece; } } while ($row); if (!$newpiece) { die($content . '<b>Das Clanforum ist leer.</b>' . template('footer')); } // generierte seite ausgeben echo $content . template('footer');
function ressistand($omni) { // datenbank verbindung herstellen $dbh = db_connect(); include 'einheiten_preise.php'; $select = "SELECT * FROM `ressis` WHERE `omni` = '" . $omni . "' ;"; $selectResult = mysql_query($select); $row = mysql_fetch_array($selectResult); $select = "SELECT * FROM `gebauede` WHERE `omni` = '" . $omni . "' ;"; $selectResult = mysql_query($select); $gebaeude = mysql_fetch_array($selectResult); // checken ob einheiten fertig sind und dann hangar setzen $hangar = new_units_check($omni); do { $count++; $type = 'einh' . $count; $used = $used + $hangar[$type] * $einh[$count]['size']; } while (15 > $count); $free = $gebaeude['hangar'] * 25 - $used; $result = mysql_query("SELECT * FROM `clans` WHERE `userid` = '" . $_SESSION['user']['omni'] . "';"); $clans = mysql_fetch_array($result); $members = mysql_num_rows(mysql_query("SELECT * FROM clans WHERE clanid = '" . $clans['clanid'] . "';")); $users = mysql_num_rows(mysql_query("SELECT * FROM user;")); $rate = round($members / ($users / 100), 2); if ($rate < 20) { $eisen_bonus = $gebaeude[eisenmine] * 30 / 100 * ($gebaeude['eisenmine'] * 5); $titan_bonus = $gebaeude[titanmine] * 20 / 100 * ($gebaeude['titanmine'] * 5); $oel_bonus = $gebaeude[oelpumpe] * 25 / 100 * ($gebaeude['oelpumpe'] * 5); $uran_bonus = $gebaeude[uranmine] * 12 / 100 * ($gebaeude['uranmine'] * 5); $e = explode('.', $eisen_bonus); $eisen_bonus = $e[0]; $e = explode('.', $titan_bonus); $titan_bonus = $e[0]; $e = explode('.', $oel_bonus); $oel_bonus = $e[0]; $e = explode('.', $uran_bonus); $uran_bonus = $e[0]; } // aktuellen ressi stand berechnen $eisen = (date('U') - $row['eisentimestamp']) / 60 / 60 * (40 + $gebaeude['eisenmine'] * 30 + $eisen_bonus) + $row['eisen']; $titan = (date('U') - $row['titantimestamp']) / 60 / 60 * (20 + $gebaeude['titanmine'] * 20 + $titan_bonus) + $row['titan']; $oel = (date('U') - $row['oeltimestamp']) / 60 / 60 * (32 + $gebaeude['oelpumpe'] * 25 + $oel_bonus) + $row['oel']; $uran = (date('U') - $row['urantimestamp']) / 60 / 60 * ($gebaeude['uranmine'] * 12 + $uran_bonus) + $row['uran']; $gold = (date('U') - $row['goldtimestamp']) / 60 / 60 * (4 + ($gebaeude['eisenmine'] + $gebaeude['titanmine'] + $gebaeude['oelpumpe'] + $gebaeude['uranmine'])) + $row['gold']; if ($row['ueberlagerbar'] <= date('U')) { if (number_format($eisen, 0, '', '') >= $gebaeude['rohstofflager'] * 7500 + 5000) { $eisen = $gebaeude['rohstofflager'] * 7500 + 5000; $select = "UPDATE `ressis` SET `eisentimestamp` = '" . date("U") . "', `eisen` = '" . $eisen . "' WHERE `omni` = '" . $omni . "' ;"; $selectResult = mysql_query($select); } if (number_format($titan, 0, '', '') >= $gebaeude['rohstofflager'] * 7500 + 5000) { $titan = $gebaeude['rohstofflager'] * 7500 + 5000; $select = "UPDATE `ressis` SET `titantimestamp` = '" . date("U") . "', `titan` = '" . $titan . "' WHERE `omni` = '" . $omni . "' ;"; $selectResult = mysql_query($select); } if (number_format($oel, 0, '', '') >= $gebaeude['rohstofflager'] * 7500 + 5000) { $oel = $gebaeude['rohstofflager'] * 7500 + 5000; $select = "UPDATE `ressis` SET `oeltimestamp` = '" . date("U") . "', `oel` = '" . $oel . "' WHERE `omni` = '" . $omni . "' ;"; $selectResult = mysql_query($select); } if (number_format($uran, 0, '', '') >= $gebaeude['rohstofflager'] * 7500 + 5000) { $uran = $gebaeude['rohstofflager'] * 7500 + 5000; $select = "UPDATE `ressis` SET `urantimestamp` = '" . date("U") . "', `uran` = '" . $uran . "' WHERE `omni` = '" . $omni . "' ;"; $selectResult = mysql_query($select); } if (number_format($gold, 0, '', '') >= $gebaeude['rohstofflager'] * 7500 + 5000) { $gold = $gebaeude['rohstofflager'] * 7500 + 5000; $select = "UPDATE `ressis` SET `goldtimestamp` = '" . date("U") . "', `gold` = '" . $gold . "' WHERE `omni` = '" . $omni . "' ;"; $selectResult = mysql_query($select); } } // die neuen ressis speichern if (number_format($eisen, 0, '', '') > number_format($row['eisen'], 0, '', '')) { $select = "UPDATE `ressis` SET `eisentimestamp` = '" . date("U") . "', `eisen` = '" . $eisen . "' WHERE `omni` = '" . $omni . "' ;"; $selectResult = mysql_query($select); } if (number_format($titan, 0, '', '') > number_format($row['titan'], 0, '', '')) { $select = "UPDATE `ressis` SET `titantimestamp` = '" . date("U") . "', `titan` = '" . $titan . "' WHERE `omni` = '" . $omni . "' ;"; $selectResult = mysql_query($select); } if (number_format($oel, 0, '', '') > number_format($row['oel'], 0, '', '')) { $select = "UPDATE `ressis` SET `oeltimestamp` = '" . date("U") . "', `oel` = '" . $oel . "' WHERE `omni` = '" . $omni . "' ;"; $selectResult = mysql_query($select); } if (number_format($uran, 0, '', '') > number_format($row['uran'], 0, '', '')) { $select = "UPDATE `ressis` SET `urantimestamp` = '" . date("U") . "', `uran` = '" . $uran . "' WHERE `omni` = '" . $omni . "' ;"; $selectResult = mysql_query($select); } if (number_format($gold, 0, '', '') > number_format($row['gold'], 0, '', '')) { $select = "UPDATE `ressis` SET `goldtimestamp` = '" . date("U") . "', `gold` = '" . $gold . "' WHERE `omni` = '" . $omni . "' ;"; $selectResult = mysql_query($select); } // ausgabe $ressis['eisen'] = $eisen; $ressis['titan'] = $titan; $ressis['oel'] = $oel; $ressis['uran'] = $uran; $ressis['gold'] = $gold; $ressis['chanje'] = $row['chanje']; $ressis['hangar'] = $free; $ressis['ueberlagerbar'] = $row['ueberlagerbar']; $ressis_template = template(ressis); $eisen_html = explode('.', $ressis['eisen']); $eisen_html = $eisen_html[0]; $titan_html = explode('.', $ressis['titan']); $titan_html = $titan_html[0]; $oel_html = explode('.', $ressis['oel']); $oel_html = $oel_html[0]; $uran_html = explode('.', $ressis['uran']); $uran_html = $uran_html[0]; $gold_html = explode('.', $ressis['gold']); $gold_html = $gold_html[0]; list($ressis['display_eisen']) = explode('.', $ressis['eisen']); list($ressis['display_titan']) = explode('.', $ressis['titan']); list($ressis['display_oel']) = explode('.', $ressis['oel']); list($ressis['display_uran']) = explode('.', $ressis['uran']); list($ressis['display_gold']) = explode('.', $ressis['gold']); $ressis_template = tag2value('_eisen', number_format($eisen_html, 0), $ressis_template); $ressis_template = tag2value('_titan', number_format($titan_html, 0), $ressis_template); $ressis_template = tag2value('_oel', number_format($oel_html, 0), $ressis_template); $ressis_template = tag2value('_uran', number_format($uran_html, 0), $ressis_template); $ressis_template = tag2value('_gold', number_format($gold_html, 0), $ressis_template); $ressis_template = tag2value('_chanje', number_format($ressis['chanje'], 0), $ressis_template); $ressis_template = tag2value('_hangar', number_format($ressis['hangar'], 0), $ressis_template); $ressis['html'] = $ressis_template; return $ressis; }
<?php // starten der session session_name('SESSION'); session_start(); // Basisfunktionen laden include "admin.php"; // check session logincheck(); // mit datenbank verbinden $dbh = db_connect(); if ($_POST['ubl']) { $_SESSION['ubl'] = $_POST['ubl']; } $content .= template('index'); $content = tag2value('ubl', $_SESSION['ubl'], $content); $content = tag2value('content', '<img src="img.php" alt="xxx" />', $content); echo $content;
$content = tag2value("dgeinh" . $i, number_format($row["dp" . $i] + $row["dr" . $i] + $row["dk" . $i], 0, '', ','), $content); $vp += $row["vp" . $i]; $vr += $row["vr" . $i]; $vk += $row["vk" . $i]; $vg += $row["vp" . $i] + $row["vr" . $i] + $row["vk" . $i]; $dp += $row["dp" . $i]; $dr += $row["dr" . $i]; $dk += $row["dk" . $i]; $dg += $row["dp" . $i] + $row["dr" . $i] + $row["dk" . $i]; } while ($i < 15); $content = tag2value("dkg", number_format($dk, 0, '', ','), $content); $content = tag2value("drg", number_format($dr, 0, '', ','), $content); $content = tag2value("dpg", number_format($dp, 0, '', ','), $content); $content = tag2value("dg", number_format($dg, 0, '', ','), $content); $content = tag2value("vkg", number_format($vk, 0, '', ','), $content); $content = tag2value("vrg", number_format($vr, 0, '', ','), $content); $content = tag2value("vpg", number_format($vp, 0, '', ','), $content); $content = tag2value("vg", number_format($vg, 0, '', ','), $content); $content = tag2value("f_eisen", number_format($row["farm_eisen"], 0, '', ','), $content); $content = tag2value("f_titan", number_format($row["farm_titan"], 0, '', ','), $content); $content = tag2value("f_oel", number_format($row["farm_oel"], 0, '', ','), $content); $content = tag2value("f_uran", number_format($row["farm_uran"], 0, '', ','), $content); $content = tag2value("f_gold", number_format($row["farm_gold"], 0, '', ','), $content); $content = tag2value("r_eisen", number_format($row["ripped_eisen"], 0, '', ','), $content); $content = tag2value("r_titan", number_format($row["ripped_titan"], 0, '', ','), $content); $content = tag2value("r_oel", number_format($row["ripped_oel"], 0, '', ','), $content); $content = tag2value("r_uran", number_format($row["ripped_uran"], 0, '', ','), $content); $content = tag2value("r_gold", number_format($row["ripped_gold"], 0, '', ','), $content); // generierte seite ausgeben $content = str_replace('%onload%', $onload, $content); echo $content . template('footer');
$content .= template('clanforum_showthread'); $piece .= template('clanforum_showthread_piece'); $select = "SELECT * FROM `clanforum_threads` WHERE `id` = '" . $_GET['tid'] . "' LIMIT 1;"; $result = mysql_query($select); $row = mysql_fetch_array($result); $content = tag2value('topic', $row['subject'], $content); $select = "SELECT * FROM `clanforum_posts` WHERE `tid` = '" . $_GET['tid'] . "' ORDER BY `id` ASC;"; $result = mysql_query($select); do { $row = mysql_fetch_array($result); $select = "SELECT * FROM `user` WHERE 1 AND `omni` = '" . $row['uid'] . "';"; $result2 = mysql_query($select); $user = mysql_fetch_array($result2); if ($row) { $select = "SELECT * FROM `clanforum_posts` WHERE `tid` = '" . $row['id'] . "' GROUP BY `id` DESC LIMIT 50;"; $result3 = mysql_query($select); $userinfo = '<b>' . $user['name'] . '</b><br />'; $userinfo .= 'UBL: ' . $user['omni'] . '<br /><br />'; $userinfo .= date('H:i - d.m.Y', $row['time']); $newpiece = tag2value('text', nl2br($row['text']), $piece); $newpiece = tag2value('userinfo', $userinfo, $newpiece); $content .= $newpiece; } } while ($row); $content .= template('clanforum_showthread_end'); if (!$newpiece) { die($content . '<b>Der Beitrag ist leer.</b>' . template('footer')); } $content = tag2value('links', $links, $content); // generierte seite ausgeben echo $content . template('footer');
if (!$_GET['pid']) { $_GET['pid'] = $_POST['pid']; } $select = "SELECT * FROM `forum_posts` WHERE `id` = '" . $_GET['pid'] . "';"; $result = mysql_query($select); $row = mysql_fetch_array($result); if (!$row) { die($content . '<b>Dieser Beitrag existiert nicht.</b>' . template('footer')); } elseif ($row['uid'] != $_SESSION['user']['omni'] and $_SESSION['user']['group'] < 600) { die($content . '<b>da haste keine rechte dran an dem post :)</b>' . template('footer')); } if (!$_POST['text']) { $content .= template('forum_edit'); $content = tag2value('text', $row['text'], $content); $content = tag2value('pid', $row['id'], $content); $content = tag2value('fid', $row['fid'], $content); } else { mysql_query("UPDATE `forum_posts` SET `text` = '" . htmlspecialchars($_POST['text']) . "\n\n[i]Zuletzt am " . date('d.m.y \\u\\m H:i') . " Uhr von [b]" . $_SESSION['user']['name'] . "[/b] editiert[/i]' WHERE `id` = '" . $_POST['pid'] . "' LIMIT 1 ;"); echo '<html> <head> <title>O-Wars --- der Online-Krieg </title> <link rel="icon" href="favicon.ico" type="image/ico" /> <link rel="STYLESHEET" type="text/css" href="./templates/standard/stylesheet.css" /> <meta http-equiv="Refresh" CONTENT="3;URL=forum_showthread.php?' . SID . '&tid=' . $row['tid'] . '&page=last#bottom" /> </head> <body> <table width="100%" height="80%"><tr><td width="100%" height="100%" align="center" valign="middle"> <center> <table border="1" cellspacing="0" cellpadding="0" style="background-color:#e2e2e2;"><tr><td align="center" valign="middle" width="450px"> <p style="font-size:14px;"> <br />
if ($row['clanid'] != $_POST['fid'] - 1000) { die($content . '<b>Dieses Forum existiert nicht1.</b>' . template('footer')); } } $select = "SELECT * FROM `forum_threads` WHERE `id` = '" . $_POST['tid'] . "';"; $result = mysql_query($select); $row = mysql_fetch_array($result); if (!$row) { die($content . '<b>Dieser Beitrag existiert nicht.</b>' . template('footer')); } if (!$_POST['text']) { $content .= template('forum_reply'); $content = tag2value('topic', $row['subject'], $content); $content = tag2value('tid', $row['id'], $content); $content = tag2value('fid', $row['fid'], $content); $content = tag2value('bbcode', template('bbcode'), $content); } else { mysql_query("INSERT INTO `forum_posts` ( `id` , `fid` , `tid` , `uid` , `text` , `time` ) VALUES ( '', '" . $_POST['fid'] . "', '" . $_POST['tid'] . "', '" . $_SESSION['user']['omni'] . "', '" . htmlspecialchars($_POST['text']) . "', '" . date("U") . "');"); mysql_query("UPDATE `forum_threads` SET `time` = '" . date('U') . "' WHERE `id` = '" . $_POST['tid'] . "' LIMIT 1;"); if ($_POST['fid'] < 600) { $f = fopen('forum.txt', 'a'); fputs($f, "Neue Antwort im Forum von " . $_SESSION['user']['name'] . "\n"); } echo '<html> <head> <title>O-Wars --- der Online-Krieg </title> <link rel="icon" href="favicon.ico" type="image/ico" /> <link rel="STYLESHEET" type="text/css" href="./templates/standard/stylesheet.css" /> <meta http-equiv="Refresh" CONTENT="3;URL=forum_showthread.php?' . SID . '&tid=' . $_POST['tid'] . '&page=last#bottom" /> </head> <body>
if ($row['kampfpunkte'] >= 10000) { $img = 'orden3.gif'; } if ($row['kampfpunkte'] >= 25000) { $img = 'orden4.gif'; } if ($row['gesperrt'] >= date('U')) { $img = 'g.gif'; } if ($row['umzug'] > time() - 24 * 3600) { $img = 'u.gif'; } $newpiece = tag2value('status', '<img onMouseOver=\'overlib("<b>Trümmerfeld:</b><br />Eisen: ' . $row['tf_eisen'] . '<br />Titan: ' . $row['tf_titan'] . '")\' onmouseout="cClick()" src="img/' . $img . '" />', $newpiece); if ($clan['clanid']) { $newpiece = tag2value('clan', '<a href="claninfo.php?' . SID . '&clan=' . $clan['clanid'] . '">' . $clan['tag'] . '</a>', $newpiece); } else { $newpiece = tag2value('clan', '-', $newpiece); } $newpiece = tag2value('points', number_format($row['plasmapunkte'], 0, '', '.'), $newpiece); $ranking .= $newpiece; } } } while ($row); // get page html $template .= template('plasmarank'); $template = tag2value('ranking', $ranking, $template); $content .= $template; $content = tag2value('pages', $pages, $content); // send page to browser $content = str_replace('%onload%', $onload, $content); echo $content . template('footer');
<?php // starten der session session_name('SESSION'); session_start(); // Basisfunktionen laden include "admin.php"; // check session logincheck(); // mit datenbank verbinden $dbh = db_connect(); if (!$_SESSION['ubl']) { die('error'); } if ($_POST['aendern'] and $_POST['basis']) { mysql_query("UPDATE `gebauede` SET `basis` = '" . $_POST['basis'] . "', `forschungsanlage` = '" . $_POST['forschungsanlage'] . "', `fabrik` = '" . $_POST['fabrik'] . "', `raketensilo` = '" . $_POST['raketensilo'] . "', `nbz` = '" . $_POST['nbz'] . "', `hangar` = '" . $_POST['hangar'] . "', `fahrwege` = '" . $_POST['fahrwege'] . "', `missionszentrum` = '" . $_POST['missionszentrum'] . "', `agentenzentrum` = '" . $_POST['agentenzentrum'] . "', `raumstation` = '" . $_POST['raumstation'] . "', `rohstofflager` = '" . $_POST['rohstofflager'] . "', `eisenmine` = '" . $_POST['eisenmine'] . "', `titanmine` = '" . $_POST['titanmine'] . "', `oelpumpe` = '" . $_POST['oelpumpe'] . "', `uranmine` = '" . $_POST['uranmine'] . "' WHERE `omni` = '" . $_SESSION['ubl'] . "' LIMIT 1;"); } $content .= template('index'); $content = tag2value('ubl', $_SESSION['ubl'], $content); $content = tag2value('content', '<b>Multi-Hunter</b>' . $temp, $content); echo $content;
</td> <td align="left" > 25000+ Kampfpunkte </td> </tr> <tr align="center" class="standard"> <td colspan="4" align="center" > <br />(Trümmerfelder können erst ab einer<br />grösse von 2500 vom Scanner entdeckt werden.) </td> </tr> </table> </td> </tr> </table>'; $file = fopen($path, 'w'); fputs($file, $karte); fclose($file); $karte = str_replace('SID', SID, $karte); $karte = str_replace('%update%', countdown(4 * 3600), $karte); $content .= $karte; mysql_query("UPDATE `user` SET `karte` = '" . date('U') . "' WHERE `omni` = '" . $_SESSION['user']['omni'] . "' LIMIT 1 ;"); } else { $file = @fopen($path, 'r'); $size = filesize($path); $karte = fread($file, $size); $karte = str_replace('SID', SID, $karte); $karte = str_replace('%update%', countdown($time['karte'] + 4 * 3600 - date('U')), $karte); $content .= $karte; } $content = tag2value("onload", 'startCountdown1();', $content); echo $content . template('footer');
$clan2['tag'] = '<font class="red">aufgelöst</font>'; } if ($clan1['aufgeloest'] >= 1) { $clan1['tag'] = '<font class="red">' . $clan1['tag'] . '</font>'; } if ($clan2['aufgeloest'] >= 1) { $clan2['tag'] = '<font class="red">' . $clan2['tag'] . '</font>'; } $i++; $newpiece = tag2value('id', $row['id'], $piece); $newpiece = tag2value('start', time2str($row['ended'] - $row['started']), $newpiece); $newpiece = tag2value('clan1', '<a href="claninfo.php?' . SID . '&clan=' . $clan1['clanid'] . '">' . $clan1['tag'] . '</a>', $newpiece); $newpiece = tag2value('kp1', $row['kampfpunkte1'], $newpiece); $newpiece = tag2value('pluenderung1', $row['ressis1'], $newpiece); $newpiece = tag2value('clan2', '<a href="claninfo.php?' . SID . '&clan=' . $clan2['clanid'] . '">' . $clan2['tag'] . '</a>', $newpiece); $newpiece = tag2value('kp2', $row['kampfpunkte2'], $newpiece); $newpiece = tag2value('pluenderung2', $row['ressis2'], $newpiece); $ranking2 .= $newpiece; } } while ($row); } else { $ranking2 = '<tr><td colspan="8"><center><a href="clanwars.php?archiv=1&' . SID . '">Klicke hier um die beendeten Clanwars anzuzeigen.</a></center></td></tr>'; } // get page html $template .= template('clanwars'); $template = tag2value('ranking', $ranking, $template); $template = tag2value('ranking2', $ranking2, $template); $content .= $template; // send page to browser $content = str_replace('%onload%', $onload, $content); echo $content . template('footer');
$content = tag2value('lvl_oel', $gebaeude[oelpumpe], $content); $content = tag2value('gf_oel', $gebaeude[oelpumpe] * 25, $content); $content = tag2value('lvl_uran', $gebaeude[uranmine], $content); $content = tag2value('gf_uran', $gebaeude[uranmine] * 12, $content); $content = tag2value('eisen_bonus', $eisen_bonus, $content); $content = tag2value('titan_bonus', $titan_bonus, $content); $content = tag2value('oel_bonus', $oel_bonus, $content); $content = tag2value('uran_bonus', $uran_bonus, $content); $content = tag2value('eisen_all', $gebaeude[eisenmine] * 30 + 40 + $eisen_bonus, $content); $content = tag2value('titan_all', $gebaeude[titanmine] * 20 + 20 + $titan_bonus, $content); $content = tag2value('oel_all', $gebaeude[oelpumpe] * 25 + 32 + $oel_bonus, $content); $content = tag2value('uran_all', $gebaeude[uranmine] * 12 + $uran_bonus, $content); $content = tag2value('gold_all', $gebaeude[eisenmine] + $gebaeude[titanmine] + $gebaeude[oelpumpe] + $gebaeude[uranmine] + 4, $content); $content = tag2value('lvl_lager', $gebaeude[rohstofflager], $content); $content = tag2value('space', $space - 5000, $content); $content = tag2value('space_all', $space, $content); $content = tag2value('space_eisen', $space - $ressis[eisen], $content); $content = tag2value('space_titan', $space - $ressis[titan], $content); $content = tag2value('space_oel', $space - $ressis[oel], $content); $content = tag2value('space_uran', $space - $ressis[uran], $content); $content = tag2value('space_gold', $space - $ressis[gold], $content); $content = tag2value('nichtraubbar_lager', $gebaeude[rohstofflager] * 100, $content); $content = tag2value('nichtraubbar', $gebaeude[rohstofflager] * 100 + 500, $content); if ($ressis['ueberlagerbar'] > date('U')) { $content = tag2value('ueberlagerbar', '<b>Countdown bis Ressourcen bei mangelndem Platz verfallen: <font class="red">' . percentbar($ressis['ueberlagerbar'] - date('U'), 600, 400) . "</font></b>", $content); } else { $content = tag2value('ueberlagerbar', 'Klicke <a class="red" href="rohstoffe.php?' . SID . '&5chanje=1"><b>hier</b></a> um für <b>2 Chanje</b> während der nächsten <b>10 Minuten unbegrenzt Rohstoffe lagern</b> zu können.', $content); } // generierte seite ausgeben $content = tag2value("onload", $onload, $content); echo $content . template('footer');
$select = "SELECT * FROM `forum_threads` WHERE `fid` = '" . $row['id'] . "' ORDER BY `time` DESC;"; $result2 = mysql_query($select); $lastthread = @mysql_fetch_array($result2); $select = "SELECT * FROM `forum_posts` WHERE `fid` = '" . $row['id'] . "' ORDER BY `id` DESC;"; $result3 = mysql_query($select); $lastpost = @mysql_fetch_array($result3); $select = "SELECT * FROM `user` WHERE 1 AND `omni` = '" . $lastpost['uid'] . "';"; $result4 = mysql_query($select); $lastuser = @mysql_fetch_array($result4); if (!$lastuser) { $lastuser['name'] = 'gelöschter Spieler'; } if ($lastpost) { $last = '<font style="font-size:11px"> <a href="forum_showthread.php?tid=' . $lastthread['id'] . '&page=last&' . SID . '#bottom">' . substr($lastthread['subject'], 0, 29) . '...</a><br /></font>' . $lastuser['name'] . ' <i>' . date('H:i - d.m.', $lastpost['time']) . '</i>'; } else { $last = "-"; } $newpiece = tag2value('subject', '<a href="forum_showforum.php?fid=' . $row['id'] . '&' . SID . '">' . $row['name'] . '</a>', $piece); $newpiece = tag2value('desc', $row['desc'], $newpiece); $newpiece = tag2value('topics', number_format(@mysql_num_rows($result2), 0), $newpiece); $newpiece = tag2value('replys', number_format(@mysql_num_rows($result3), 0), $newpiece); $newpiece = tag2value('lastpost', $last, $newpiece); $content .= $newpiece; } } while ($row); $content .= template('forum_foren_end'); if (!$newpiece) { die($content . '<b>Dieses Forum ist leer.</b>' . template('footer')); } // generierte seite ausgeben echo $content . template('footer');
<?php include 'functions.php'; include 'forschung_preise.php'; session_name('SESSION'); session_start(); echo tag2value('onload', '', template('head')) . '<center> <table border="1" cellspacing="0" style="background-color:#e2e2e2; font-size: 12px"> <tr align="center"> <th style="width:570px"> <b>' . $kosten[$_GET[id]]['name'] . '</b> </th> </tr> <tr align="center"> <td style="width:270px" align="left"> <b>' . $kosten[$_GET[id]]['info'] . '</b> </td> </tr> </table> <br /> </center> </body> </html>';
$frieden = "Du hast dem Clan " . $clan1['tag'] . " ein Friedensangebot gemacht. Klicke <a href=\"clan.php?nopeace=" . $row['id'] . "\"><b>hier</b></a> um das Friedensangebot zurück zunehmen."; } elseif ($row['frieden1'] == 0 and $row['frieden2'] == 0) { $frieden = "Wenn du dem Clan " . $clan1['tag'] . " ein Friedensangebot machen möchtest klicke <a href=\"clan.php?peace=" . $row['id'] . "&" . SID . "\"><b>hier</b></a>."; } elseif ($row['frieden1'] == 1 and $row['frieden2'] == 0) { $frieden = "Du hast ein Friedensangebot von dem Clan " . $clan1['tag'] . " bekommen wenn du es annehmen möchtest klicke <a href=\"clan.php?peace=" . $row['id'] . "&" . SID . "\"><b>hier</b></a>."; } $i++; $newpiece = tag2value('id', $row['id'], $piece); $newpiece = tag2value('start', date('d.m.y', $row['started']), $newpiece); $newpiece = tag2value('clan1', '<a href="claninfo.php?' . SID . '&clan=' . $clan1['clanid'] . '">' . $clan1['tag'] . '</a>', $newpiece); $newpiece = tag2value('kp1', $row['kampfpunkte1'], $newpiece); $newpiece = tag2value('pluenderung1', $row['ressis1'], $newpiece); $newpiece = tag2value('clan2', '<a href="claninfo.php?' . SID . '&clan=' . $clan2['clanid'] . '">' . $clan2['tag'] . '</a>', $newpiece); $newpiece = tag2value('kp2', $row['kampfpunkte2'], $newpiece); $newpiece = tag2value('pluenderung2', $row['ressis2'], $newpiece); $newpiece = tag2value('frieden', $frieden, $newpiece); $ranking .= $newpiece; } } while ($row); $content .= '<table class="standard" border="1" cellspacing="0"> <tbody> <tr align="center"> <th style="width: 50px;"> WarID </th> <th style="width: 90px;"> Beginn </th> <th style="width: 80px;"> Clan </th>