is_ingelogd()){ if (!empty($_GET['edit']) && $_GET['edit'] == 1){ if (!empty($_POST['opslaan'])){ if ($page_class->update($_POST['id'], $_POST['inhoud'])){ $smarty->assign('message', 'Opslaan gelukt'); } else { $smarty->assign('message', 'Opslaan mislukt'); } } else { if(!$page_class->bestaat_pagina($page)) { $page_class->add($page,''); } if($item = $page_class->get_all_info($page)) { $smarty->assign('item', $item); $smarty->assign('edit', true); } } } } $smarty->assign('page', stripslashes($page_class->get($page))); $smarty->display('index.tpl'); ?>