| 1 |
<?php |
|---|
| 2 |
/* |
|---|
| 3 |
*Name : uninstall.php |
|---|
| 4 |
*Author : Michael Yara |
|---|
| 5 |
*Created : August 15, 2008 |
|---|
| 6 |
*Last Updated : May 26, 2009 |
|---|
| 7 |
*History : 0.3 |
|---|
| 8 |
*Purpose : Remove iSymphony tables and manager include |
|---|
| 9 |
*Copyright : 2008 HEHE Enterprises, LLC |
|---|
| 10 |
*/ |
|---|
| 11 |
|
|---|
| 12 |
global $db; |
|---|
| 13 |
|
|---|
| 14 |
//Drop location table |
|---|
| 15 |
$query = "DROP TABLE IF EXISTS isymphony_location"; |
|---|
| 16 |
echo "Removing \"isymphony_location\" Table....<br>"; |
|---|
| 17 |
$results = $db->query($query); |
|---|
| 18 |
if(DB::IsError($results)) { |
|---|
| 19 |
echo "ERROR: could not remove table.<br>"; |
|---|
| 20 |
} |
|---|
| 21 |
|
|---|
| 22 |
//Drop users table |
|---|
| 23 |
$query = "DROP TABLE IF EXISTS isymphony_users"; |
|---|
| 24 |
echo "Removing \"isymphony_users\" Table....<br>"; |
|---|
| 25 |
$results = $db->query($query); |
|---|
| 26 |
if(DB::IsError($results)) { |
|---|
| 27 |
echo "ERROR: could not remove table.<br>"; |
|---|
| 28 |
} |
|---|
| 29 |
|
|---|
| 30 |
//Drop queues table |
|---|
| 31 |
$query = "DROP TABLE IF EXISTS isymphony_queues"; |
|---|
| 32 |
echo "Removing \"isymphony_queues\" Table....<br>"; |
|---|
| 33 |
$results = $db->query($query); |
|---|
| 34 |
if(DB::IsError($results)) { |
|---|
| 35 |
echo "ERROR: could not remove table.<br>"; |
|---|
| 36 |
} |
|---|
| 37 |
|
|---|
| 38 |
//Drop conference rooms table |
|---|
| 39 |
$query = "DROP TABLE IF EXISTS isymphony_conference_rooms"; |
|---|
| 40 |
echo "Removing \"isymphony_conference_rooms\" Table....<br>"; |
|---|
| 41 |
$results = $db->query($query); |
|---|
| 42 |
if(DB::IsError($results)) { |
|---|
| 43 |
echo "ERROR: could not remove table.<br>"; |
|---|
| 44 |
} |
|---|
| 45 |
|
|---|
| 46 |
//Remove manager entry |
|---|
| 47 |
$query = "DELETE FROM manager WHERE name = 'isymphony'"; |
|---|
| 48 |
echo "Removing manager entry....<br>"; |
|---|
| 49 |
$results = $db->query($query); |
|---|
| 50 |
if(DB::IsError($results)) { |
|---|
| 51 |
echo "ERROR: could not remove manager entry.<br>"; |
|---|
| 52 |
} |
|---|
| 53 |
?> |
|---|