if (isset($startpageid)) {
if ($_GET['actie'] == "Y"){
mysql_query("UPDATE pages SET startpage = 'N' WHERE startpage = 'Y' ") or die(mysql_error());
mysql_query("UPDATE pages SET startpage = 'Y' WHERE id = '".$startpageid."'") or die(mysql_error());
echo "<script>location.href='$PHP_SELF'</script>";
} else {
mysql_query("UPDATE pages_t_details SET startpage = 'Y' WHERE id = '".$startpageid."'") or die(mysql_error());
echo "<script>location.href='$PHP_SELF'</script>";
}
}