Files
wachter/index.php

114 lines
4.5 KiB
PHP

<?php
error_reporting(E_ALL ^ E_NOTICE);
// error_reporting(E_ALL);
// error_reporting(E_ALL | E_STRICT);
include "inc/config.php"; // die Konfigurationsdateien lesen
$db = @new MySQLi(MYSQL_HOST, MYSQL_USER, MYSQL_PASS, MYSQL_DATABASE);
$db->set_charset('utf8');
if (mysqli_connect_errno()) {
die('Konnte keine Verbindung zu Datenbank aufbauen, MySQL meldete: '.mysqli_connect_error());
}
include "inc/funktionen.php";
if ( isset ( $_GET['pdf'] ) AND "create" == $_GET['pdf']) {
include "inhalte/pdf/pdf.php";
}
$title = "Wachter Immobilien";
$tags = '';
if ( isset ( $_GET['obj'] ) AND ( !empty ( $_GET['obj'] ) ) )
{
$sql = "SELECT * FROM objekte WHERE ID = '" . $_GET['obj'] . "' LIMIT 1;";
$result = $db->query ( $sql );
$nt = $result->fetch_assoc ();
$title .= ': ' . $nt['Kurz'] . ' in ' . $nt['Ort'];
$tags = $nt['Tags'];
}
elseif ( isset ( $_GET['section'] ) AND ( 'unter' == $_GET['section'] ) )
{
$title .= ": Das Unternehmen";
}
elseif ( isset ( $_GET['section'] ) AND ( 'immobilien' == $_GET['section'] ) )
{
if ( isset ( $_GET['topic'] ) )
{
$temp_title = explode ( '_', $_GET['topic'] );
$title .= ': ' . strtoupper(substr($temp_title[0], 0,1)) . substr($temp_title[0], 1) . ' ' . strtoupper(substr($temp_title[1], 0,1)) . substr($temp_title[1], 1);
}
else
{
$title .= 'Immobilien';
}
}
echo "<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Strict//EN\"\n";
echo " \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd\">\n";
echo "<html xmlns=\"http://www.w3.org/1999/xhtml\">\n";
echo " <head>\n";
echo " <title>".$title."</title>\n";
echo " <link rel=\"stylesheet\" media=\"screen, projection\" type=\"text/css\" href=\"css/page.css\" />\n";
echo " <link rel=\"stylesheet\" media=\"print\" type=\"text/css\" href=\"css/print.css\" />\n";
?>
<link rel="icon" href="favicon.ico" type="image/x-icon" />
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<meta http-equiv="language" content="deutsch, de" />
<meta name="description" content="Wachter Immobilien - Vermittlung und Verwaltung von Immobilien" />
<meta name="keywords" content="Immobilien, <?php echo $tags; ?> " />
<meta name="author" content=" Wachter Immobilien " />
<meta name="copyright" content=" (c) Wachter Immobilien" />
<meta name="page-topic" content=" Immobilien, Wohnungen, Häuser, Miete, Kauf, Verwaltung " />
<meta name="robots" content="index,follow" />
<meta name="revisit-after" content="10 days" />
<script type="text/javascript">
function fnc_getBodySize ( )
{
var the_bg = document.getElementById ( 'background' );
the_bg.style.height = ( parseInt ( document.body.clientHeight ) - 253 ) + 'px';
}
</script>
<?php
echo " </head>\n";
echo " <body onload=\"fnc_getBodySize();\">\n";
echo " <div id=\"background\"></div>\n";
echo " <div id=\"frame\">\n";
echo " <div id=\"page\">\n";
echo " <div id=\"header_box\">\n"; // Oben der Header
echo " <div id=\"header\">\n";
include "header.php";
echo " </div>\n";
echo " <br class=\"noDisplay\" /><hr class=\"noDisplay\" />\n";
echo " </div>\n";
echo " <div id=\"main\">\n"; // ganz oberer Div-Holder
echo " <div id=\"wrap\">\n";
echo " <div id=\"inhalt_box\" ";
if (("produkte" == $_GET[section]) AND ("" == $_GET[t])) {
echo "style=\"background-image:none;\" ";
}
echo ">\n";
echo " <div id=\"inhalt\">\n";
include "inhalt.php";
echo " </div>\n";
echo " </div>\n";
echo " <br class=\"noDisplay\" /><hr class=\"noDisplay\" />\n";
echo " <div id=\"links_box\">\n";
echo " <div id=\"links\">\n";
include "left.php";
echo " </div>\n";
echo " </div>\n";
echo " <br class=\"noDisplay\" /><hr class=\"noDisplay\" />\n";
echo " </div>\n";
echo " </div>\n";
echo " <br class=\"fix\" />\n";
echo " <div id=\"footer_box\">\n";
echo " <div id=\"footer\">\n";
include "footer.php";
echo " </div>\n";
echo " </div>\n";
echo " </div>\n";
echo " </div>\n";
echo " </body>\n";
echo "</html>\n";
?>