summaryrefslogtreecommitdiffstats
path: root/pbs-randomDelete.php
diff options
context:
space:
mode:
authorSimon2011-03-25 17:51:50 +0100
committerSimon2011-03-25 17:51:50 +0100
commit28f45e155a12db3b27682e84896b3f6a6b1c794a (patch)
tree2238c5a430d5928cb6dddb11f717f8edbfa9d66c /pbs-randomDelete.php
parentMerge branch 'master' of openslx.org:lsfks/master-teamprojekt/pbs2 (diff)
downloadpbs2-28f45e155a12db3b27682e84896b3f6a6b1c794a.tar.gz
pbs2-28f45e155a12db3b27682e84896b3f6a6b1c794a.tar.xz
pbs2-28f45e155a12db3b27682e84896b3f6a6b1c794a.zip
Nicht Benötigte Tabellen, Models, Mapper und Dateien entfernt
Diffstat (limited to 'pbs-randomDelete.php')
-rw-r--r--pbs-randomDelete.php65
1 files changed, 0 insertions, 65 deletions
diff --git a/pbs-randomDelete.php b/pbs-randomDelete.php
deleted file mode 100644
index c3a7014..0000000
--- a/pbs-randomDelete.php
+++ /dev/null
@@ -1,65 +0,0 @@
-<?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){
- $anz = mysql_num_rows(mysql_query('SELECT * FROM pbs_membership WHERE personID = $i'));
- mysql_query('DELETE FROM pbs_person WHERE personID = $i;');
- if(mysql_num_rows(mysql_query("SELECT * FROM pbs_person WHERE personID = $i;") < 1)){
- if($anz > 0) {
- if(mysql_num_rows(mysql_query("SELECT * FROM pbs_membership WHERE personID = $i;")) < 1) {
- echo "Löschen erfolgreich";
- } else {
- echo "Löschen nicht erfolgreich";
- }
- } else {
- echo "Löschen erfolgreich";
- }
- } else {
- echo "Löschen nicht erfolgreich";
- }
- }
-
- public function deleteGroup($i){
-
- }
-
- public function deleteRight($i){
-
- }
-
- public function deleteRole($i){
-
- }
-
- public function deleteMemberships(){
-
- }
-
- public function deleteAll(){
- $this->deletePerson(20);
- $this->deleteGroup(10);
- $this->deleteRight(20);
- $this->deleteRole(20);
- $this->deleteMemberships();
- }
-}
-
-$u = new deleteClass();
-$u->deleteAll();
-
-