summaryrefslogtreecommitdiffstats
path: root/pbs-randomDelete.php
blob: 28b6c389eb151afbd1c18c85388ce1c835906da8 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
<?php
class deleteClass{
	private $link;

	public function __construct() {
		$this->link = mysql_connect('localhost', 'root', 'lsfks-openslx');
		if (!$this->link) {
			die('keine Verbindung möglich: ' . mysql_error());
		}
		echo 'Verbindung erfolgreich'."\n";
		mysql_select_db('pbs');
	}

	public function __destruct() {
		mysql_close($this->link);
		unset($this->link);
	}

	public function deletePerson($i){
		
	}
	
	public function deleteGroup($i){
		
	}
	
	public function deleteRight($i){
		
	}

	public function deleteRole($i){
		
	}
	
	public function deleteMemberships(){
		
	}
	
	public function deleteAll(){
		$this->deleteGroup(10);
		$this->deletePerson(20);
		$this->deleteRight(20);
		$this->deleteRole(20);
		$this->deleteMemberships();
	}
}

$u = new deleteClass();
$u->deleteAll();