<?php

if (!in_array("Stammdaten", $_SESSION['Rechte'])) {
	exit(ZUGRIFF_ERROR);
}
if (!isset($_SESSION['ID'])) {
} else {
    if (("Löschen" == $_POST['action']) OR ("Abbrechen" == $_POST['action'])) {
		$sql1 = 'DELETE FROM
					Team
				WHERE
					ID = "'.$_POST['ID'].'";';
		$result1 = $db->query($sql1);
		$sql2 = 'DELETE FROM
					admins
				WHERE
					ID = "'.$_POST['ID'].'";';
		$result2 = $db->query($sql2);
		if ($result1 AND $result2) {
			unset($_POST);
			include "inhalte/stammdaten/unter/tm_over.php";
		} else {
			echo "Fehler beim löschen";
		}
    }
} 

?>