X-Git-Url: https://git.ccc-ffm.de/?p=memberdb.git;a=blobdiff_plain;f=index.php;h=889a6f1bf041452d8d7319573cba6360b6a90a2a;hp=424fa5f89005c772770c3f753c274c0500e0f975;hb=8b7f5100aa1eb5201ccfcf671e844b31ea60cd01;hpb=4ca90a0df643b19fc4405921ae2e8500eae97e22 diff --git a/index.php b/index.php index 424fa5f..889a6f1 100644 --- a/index.php +++ b/index.php @@ -1,450 +1,440 @@ getMessage()); + exit(); +}); + +require_once(__DIR__ . '/include/autoload.php'); + +if (!file_exists(__DIR__ . '/config.php')) { + die('Not configured'); +} + require_once('config.php'); -require_once('include/database.php'); -require_once('include/misc.php'); -require_once('include/installation.php'); -require_once('include/html.php'); - -require_once('include/finances.php'); -require_once('include/fees.php'); -require_once('include/cryptography.php'); -require_once('include/earnings.php'); -require_once('include/events.php'); -require_once('include/expenses.php'); -require_once('include/members.php'); -require_once('include/payments.php'); -require_once('include/directdebit.php'); -require_once('include/xlsexport.php'); - - -try { - - db_connect(); - - if (!defined('IS_INSTALLED') || !IS_INSTALLED) { - install_database(); - } - - $action = 'list_members'; - if (isset($_REQUEST['action'])) { - $action = $_REQUEST['action']; - } - - ob_start(); - - switch ($action) { - case 'list_members' : - action_list_members(); - break; - case 'view_member' : - action_view_member(); - break; - case 'export_email' : - action_export_email(); - break; - case 'create_member' : - action_create_member(); - break; - case 'change_member' : - action_change_member(); - break; - case 'export_ibanhin' : - action_export_ibanhin(); - break; - case 'create_event' : - action_create_event(); - break; - case 'change_event' : - action_change_event(); - break; - case 'delete_event' : - action_delete_event(); - break; - case 'create_earnings': - action_create_earnings(); - break; - case 'create_earning' : - action_create_earning(); - break; - case 'change_earning' : - action_change_earning(); - break; - case 'delete_earning' : - action_delete_earning(); - break; - case 'create_expense' : - action_create_expense(); - break; - case 'change_expense' : - action_change_expense(); - break; - case 'delete_expense' : - action_delete_expense(); - break; - case 'cryptography' : - action_cryptography(); - break; - case 'fees' : - action_fees(); - break; - case 'directdebit' : - action_directdebit(); - break; - case 'finances' : - action_finances(); - break; - case 'export' : - action_export_payments(); - break; - case 'export_members' : - action_export_members(); - break; - default: - action_404(); - } - - $content = ob_get_contents(); - ob_end_clean(); - - ?> - - - - - Mitgliedsverwaltung - Chaos Computer Club Frankfurt am Main - - - - - - - - - - - - - - - - - -
- - - - - getMessage(), "\n"; +require_once(__DIR__ . '/include/includes.php'); + + +db_connect(); + +if (!defined('IS_INSTALLED') || !IS_INSTALLED) { + install_database(); +} + +$action = 'list_members'; +if (isset($_GET['action'])) { + $action = $_GET['action']; } + +ob_start(); + +switch ($action) { + case 'list_members' : + action_list_members(); + break; + case 'view_member' : + action_view_member(); + break; + case 'export_email' : + action_export_email(); + break; + case 'create_member' : + action_create_member(); + break; + case 'change_member' : + action_change_member(); + break; + case 'export_ibanhin' : + action_export_ibanhin(); + break; + case 'create_event' : + action_create_event(); + break; + case 'change_event' : + action_change_event(); + break; + case 'delete_event' : + action_delete_event(); + break; + case 'create_earnings': + action_create_earnings(); + break; + case 'create_earning' : + action_create_earning(); + break; + case 'change_earning' : + action_change_earning(); + break; + case 'delete_earning' : + action_delete_earning(); + break; + case 'create_expense' : + action_create_expense(); + break; + case 'change_expense' : + action_change_expense(); + break; + case 'delete_expense' : + action_delete_expense(); + break; + case 'cryptography' : + action_cryptography(); + break; + case 'fees' : + action_fees(); + break; + case 'directdebit' : + action_directdebit(); + break; + case 'finances' : + action_finances(); + break; + case 'export' : + action_export_payments(); + break; + case 'export_members' : + action_export_members(); + break; + default: + action_404(); +} + +$content = ob_get_contents(); +ob_end_clean(); + +?> + + + + + Mitgliedsverwaltung - Chaos Computer Club Frankfurt am Main + + + + + + + + + + + + + + + + + +
+ + +