<?php include './functions.php'; include './htmlHelpers.php'; renderHtmlStart("Home", ""); ?> <div> <?php // welkoms text (WelkomsTtekst asshole) $uitvoerDatabase = query("SELECT Welkomstekst FROM welkomstekst WHERE ID = 1", NULL); foreach ($uitvoerDatabase as $value1) { foreach ($value1 as $value2) { echo "<h4 id='welkomstekst'>{$value2}</h4>"; } } ?> </div> <?php // slider ?> <script src="slider.js"></script> <div class="slider2"> <a href="#" class="control_next"><span class="glyphicon glyphicon-chevron-right"></span></a> <a href="#" class="control_prev"><span class="glyphicon glyphicon-chevron-left"></span></a> <div id="slider"> <ul> <?php // schilderijen voor slider ophalen uit database $categorieen = query("SELECT CategorieID FROM schilderij WHERE OpWebsite = 1 GROUP BY CategorieID HAVING COUNT(*) >= 3 LIMIT 0,5", null);
<?php include './htmlHelpers.php'; //include './admin/functions.php'; include './functions.php'; renderHtmlStart("Contact", ""); ?> <?php /* error messages */ $contact_voornaam_error = ""; $contact_achternaam_error = ""; $contact_email_error = ""; $contact_onderwerp_error = ""; $contact_bericht_error = ""; $controle = true; /* voorafingestelde values forms */ $mail = ""; $contact_voornaam = ""; $contact_achternaam = ""; $contact_email = ""; $contact_onderwerp = ""; $contact_bericht = ""; ?> <?php if (isset($_POST["contact-submit"]) && $_POST["contact-submit"] == "Verzenden") { $contact_voornaam = $_POST["contact-voornaam"]; $contact_achternaam = $_POST["contact-achternaam"]; $contact_email = $_POST["contact-email"]; $contact_onderwerp = $_POST["contact-onderwerp"];
<?php include './htmlHelpers.php'; include './functions.php'; renderHtmlStart("Gallerij", "<script src='/content/gallerij.js'></script>"); ?> <div class="gallerij"> <div id="gallerijcategorie"> <?php $selectedcat = 0; if (isset($_GET['categorie'])) { $selectedcat = $_GET['categorie']; echo '<a href="gallerij.php">Alles</a> | '; } else { echo '<span class="selected">Alles</span> | '; } $categorieen = query("SELECT * FROM categorie", null); $i = 1; foreach ($categorieen as $cat) { if ($selectedcat == $cat["CategorieID"]) { echo '<span class="selected">' . $cat["Categorie_naam"] . '</a>'; } else { echo '<a href="gallerij.php?categorie=' . $cat["CategorieID"] . '">' . $cat["Categorie_naam"] . '</a>'; } if ($i < count($categorieen)) { echo " | "; } $i++; } ?>
<?php include './htmlHelpers.php'; include './functions.php'; renderHtmlStart("Zoeken", ""); $where = " WHERE OpWebsite = 1 "; $params = array(); $zoek = ""; //checken of het knopje is ingedrukt if (isset($_GET['button'])) { //checken of categorie is ingevuld if (isset($_GET["categorie"])) { if ($_GET["categorie"] != "Alles") { $where .= " AND CategorieID = ? "; $params[] = $_GET["categorie"]; } } //checken of materiaal is ingevuld if (isset($_GET["materiaal"])) { if ($_GET["materiaal"] != "Alles") { $where .= " AND MateriaalID = ? "; $params[] = $_GET["materiaal"]; } } // zoek op tekst if ($_GET['zoek'] != "") { $zoek = $_GET['zoek']; $where .= " AND (Titel LIKE ? OR Beschrijving LIKE ?) "; $params[] = "%{$zoek}%"; $params[] = "%{$zoek}%"; }
<?php session_start(); require 'functions.php'; require '../htmlHelpers.php'; renderHtmlStart("inlog", '<link href="../content/admin.css" type="text/css" rel="stylesheet">'); if (isLoggedIn()) { header("location: main.php"); } else { include 'inlog.php'; } renderHtmlEnd();
<?php include './htmlHelpers.php'; include './functions.php'; renderHtmlStart("Schilderij", ""); ?> <script src="https://www.google.com/recaptcha/api.js?onload=onloadCallback&render=explicit" async defer> </script> <?php $params = array($_GET["id"]); // eerst schilderij ophalen $schilderijlijst = query("SELECT S.titel, S.jaar, S.hoogte, S.breedte, S.beschrijving, \n C.Categorie_naam, SC.Subcategorie_naam, M.Materiaal_soort, S.img, S.prijs, S.lijst, \n S.passepartout, S.isStaand\n FROM schilderij S \n JOIN categorie C ON C.CategorieID = S.CategorieID \n LEFT JOIN subcategorie SC ON SC.SubcategorieID = S.SubcategorieID \n JOIN materiaal M ON M.MateriaalID = S.MateriaalID\n \n WHERE S.Schilderij_ID = ? AND S.OpWebsite = 1", $params); if (count($schilderijlijst) != 1) { header("location: gallerij.php"); exit; } $schilderij = $schilderijlijst[0]; $naam = ""; $commentaar = ""; $email = ""; $correct = true; if (isset($_POST["naam"]) && isset($_POST["commentaar"]) && checkCaptcha($_POST["g-recaptcha-response"])) { $commentaar = uppercase($_POST["commentaar"]); $naam = trim($_POST["naam"]); if ($naam == "") { $naamleeg = "Naam is verplicht"; $correct = false; } if ($commentaar == "") {