Optimierung des Kontaktformulars: Entfernen von nicht benötigten Feldern und Verbesserung der Validierungslogik. Anpassung der CSS-Stile für eine bessere Benutzererfahrung.

This commit is contained in:
Samuel Müller
2025-08-01 10:56:13 +02:00
parent 0c44e675e8
commit cdcf060b0e
10 changed files with 2061 additions and 0 deletions

View File

@@ -0,0 +1,56 @@
<footer class="footer">
<div class="container">
<div class="footer-content">
<div class="footer-section">
<h4>HexaHost.de</h4>
<p>Zuverlässiges Hosting aus Niederbayern</p>
<div class="footer-location">
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
<path d="M21 10c0 7-9 13-9 13s-9-6-9-13a9 9 0 0 1 18 0z"/>
<circle cx="12" cy="10" r="3"/>
</svg>
<span>Niederbayern, Deutschland</span>
</div>
</div>
<div class="footer-section">
<h4>Produkte</h4>
<ul>
<li><a href="vpc.html">Virtual Private Container</a></li>
<li><a href="vps.html">Virtual Private Server</a></li>
<li><a href="mail-gateway.html">Mail Gateway</a></li>
<li><a href="webhosting.html">Webhosting</a></li>
</ul>
</div>
<div class="footer-section">
<h4>Unternehmen</h4>
<ul>
<li><a href="about.html">Über uns</a></li>
<li><a href="contact.html">Kontakt</a></li>
<li><a href="#">Impressum</a></li>
<li><a href="#">Datenschutz</a></li>
</ul>
</div>
<div class="footer-section">
<h4>Support</h4>
<ul>
<li><a href="#">Hilfe-Center</a></li>
<li><a href="#">Status</a></li>
<li><a href="contact.html">Support-Ticket</a></li>
<li><a href="#">FAQ</a></li>
</ul>
</div>
</div>
<div class="footer-bottom">
<p>&copy; 2024 HexaHost.de - Alle Rechte vorbehalten</p>
</div>
</div>
</footer>
<script src="assets/js/main.js"></script>
<?php if (isset($additional_scripts)): ?>
<?php foreach ($additional_scripts as $script): ?>
<script src="<?php echo $script; ?>"></script>
<?php endforeach; ?>
<?php endif; ?>
</body>
</html>

View File

@@ -0,0 +1,68 @@
<?php
/**
* Helper functions for HexaHost.de
*/
/**
* Set page configuration and include header
*
* @param string $page_title The page title
* @param string $page_description The page description
* @param string $current_page The current page identifier
* @param array $additional_scripts Additional scripts to include
*/
function includeHeader($page_title = '', $page_description = '', $current_page = '', $additional_scripts = []) {
global $page_title, $page_description, $current_page, $additional_scripts;
// Set default values if not provided
if (empty($page_title)) {
$page_title = 'HexaHost.de - Zuverlässiges Hosting aus Niederbayern';
}
if (empty($page_description)) {
$page_description = 'HexaHost.de - Zuverlässiges und preiswertes Hosting aus Niederbayern. VPS, VPC, Mail Gateway und Webhosting Lösungen.';
}
include 'includes/header.php';
}
/**
* Include footer
*/
function includeFooter() {
include 'includes/footer.php';
}
/**
* Generate breadcrumb navigation
*
* @param array $breadcrumbs Array of breadcrumb items [['title' => 'Home', 'url' => 'index.html'], ...]
*/
function generateBreadcrumbs($breadcrumbs) {
echo '<div class="breadcrumb">';
$last_index = count($breadcrumbs) - 1;
foreach ($breadcrumbs as $index => $item) {
if ($index === $last_index) {
// Last item (current page)
echo '<span>' . htmlspecialchars($item['title']) . '</span>';
} else {
// Link to other pages
echo '<a href="' . htmlspecialchars($item['url']) . '">' . htmlspecialchars($item['title']) . '</a>';
echo '<span>/</span>';
}
}
echo '</div>';
}
/**
* Generate CSRF token for form security
*
* @return string CSRF token
*/
function generateCSRFToken() {
if (!isset($_SESSION['csrf_token'])) {
$_SESSION['csrf_token'] = bin2hex(random_bytes(32));
}
return $_SESSION['csrf_token'];
}
?>

View File

@@ -0,0 +1,45 @@
<!DOCTYPE html>
<html lang="de">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title><?php echo isset($page_title) ? $page_title : 'HexaHost.de - Zuverlässiges Hosting aus Niederbayern'; ?></title>
<link rel="stylesheet" href="assets/css/style.css">
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Russo+One&family=Source+Sans+Pro:wght@300;400;600;700&display=swap" rel="stylesheet">
<link rel="icon" type="image/svg+xml" href="favicon.svg">
<meta name="description" content="<?php echo isset($page_description) ? $page_description : 'HexaHost.de - Zuverlässiges und preiswertes Hosting aus Niederbayern. VPS, VPC, Mail Gateway und Webhosting Lösungen.'; ?>">
</head>
<body>
<header class="header">
<nav class="nav">
<div class="nav-container">
<div class="nav-logo">
<a href="index.html">
<span class="logo-text">HexaHost</span>
<span class="logo-tld">.de</span>
</a>
</div>
<ul class="nav-menu">
<li><a href="index.html" class="nav-link <?php echo ($current_page === 'home') ? 'active' : ''; ?>">Home</a></li>
<li class="nav-dropdown">
<a href="#" class="nav-link <?php echo (in_array($current_page, ['vpc', 'vps', 'mail-gateway', 'webhosting'])) ? 'active' : ''; ?>">Produkte</a>
<ul class="dropdown-menu">
<li><a href="vpc.php" class="<?php echo ($current_page === 'vpc') ? 'active' : ''; ?>">Virtual Private Container</a></li>
<li><a href="vps.php" class="<?php echo ($current_page === 'vps') ? 'active' : ''; ?>">Virtual Private Server</a></li>
<li><a href="mail-gateway.php" class="<?php echo ($current_page === 'mail-gateway') ? 'active' : ''; ?>">Mail Gateway</a></li>
<li><a href="webhosting.php" class="<?php echo ($current_page === 'webhosting') ? 'active' : ''; ?>">Webhosting</a></li>
</ul>
</li>
<li><a href="about.html" class="nav-link <?php echo ($current_page === 'about') ? 'active' : ''; ?>">Über uns</a></li>
<li><a href="contact.html" class="nav-link <?php echo ($current_page === 'contact') ? 'active' : ''; ?>">Kontakt</a></li>
</ul>
<div class="nav-toggle">
<span></span>
<span></span>
<span></span>
</div>
</div>
</nav>
</header>