$val) { if($sub[1].".".$sub[2] == $val) { $gdom = $key; } } $sub = $sub[0]; // Tijdelijk homepage uit mits geen testpagina vanuit beheer if($sub != "admin") { include("startpagina.php"); } else { $template->set_filenames(array( 'content' => 'index.tpl' )); if($_SESSION['bezocht'] !== "ja" && strlen($HTTP_REFERER) > 7) { $url = str_replace('http://', '/', $HTTP_REFERER); $url = explode("/", $url); $query = mysql_query("UPDATE bsp_partners SET inhits=inhits + 1 WHERE url LIKE 'http://$url[1]%' AND domein = 0") or die(mysql_error()); $_SESSION['bezocht'] = 'ja'; } $query = mysql_query("SELECT * FROM bsp_nieuws ORDER BY nid DESC LIMIT 3") or die(mysql_error()); while($ob = mysql_fetch_object($query)) { $template->assign_block_vars('nieuws', array( 'titel' => $ob->titel, 'artikel' => trim(nl2br($ob->artikel)), 'img' => ( file_exists("data/nieuws/$ob->nid.jpg") ? "" : '' ) )); } $dagen = array("Zon","Maa","Din","Woe","Don","Vrij","Zat"); $i = 0; $query = mysql_query("SELECT domein,gdomein FROM bsp_domeinen WHERE active = 1 ORDER BY id DESC LIMIT 10") or die(mysql_error()); while($ob = mysql_fetch_object($query)) { $i++; $template->assign_block_vars('nieuwste_domeinen', array( 'rij' => ( ($i % 2) <> 0 ? "rij1" : "rij2" ), 'nr' => $i, 'domein' => $ob->domein, 'gdomein'=> $KDOMEINEN[$ob->gdomein] )); } $i = 0; $query = mysql_query("SELECT domein,gdomein FROM bsp_domeinen WHERE active = 1 ORDER BY aantallinks DESC LIMIT 10") or die(mysql_error()); while($ob = mysql_fetch_object($query)) { $i++; $template->assign_block_vars('meeste_links', array( 'rij' => ( ($i % 2) == 0 ? "rij1" : "rij2" ), 'nr' => $i, 'domein' => $ob->domein, 'gdomein'=> $KDOMEINEN[$ob->gdomein] )); } include('includes/footer.inc.php'); } ?>