session_start(); if ($_SESSION['loggedIn']) { include 'functions.php'; $page_id = $_GET['page_id']; $result = runQuery("SELECT * FROM ebreimer_pages WHERE page_id = '$page_id'"); $page = mysql_fetch_array($result); if($_POST['action'] == "Edit Page") { $pageName = $_POST['page_name']; $pageColor = $_POST['page_color']; $pageContents = $_POST['page_contents']; if ($pageName != "" && $pageColor != "" && $pageContents != "") runQuery("UPDATE ebreimer_pages SET page_name = '$pageName', page_color = '$pageColor', page_contents ='$pageContents' WHERE page_id='$pageID'"); } } ?>