diff options
| author | George Halkiadakis <gchalkiadakis@sklavenitis.co.gr> | 2023-03-31 05:49:40 +0300 |
|---|---|---|
| committer | George Halkiadakis <gchalkiadakis@sklavenitis.co.gr> | 2023-03-31 05:49:40 +0300 |
| commit | c95daba5206cb4bd55b5685e8141311f23606e1a (patch) | |
| tree | dcf3ab236cbf60c4d2ffc8af9a520804f504a437 /html/app/config | |
| parent | 4f2d900af7636e6744ae14aeeefdf2d6080ac50a (diff) | |
| download | classroom-c95daba5206cb4bd55b5685e8141311f23606e1a.tar.gz classroom-c95daba5206cb4bd55b5685e8141311f23606e1a.tar.bz2 classroom-c95daba5206cb4bd55b5685e8141311f23606e1a.zip | |
added advances and secure confifuratin parametres
Diffstat (limited to 'html/app/config')
| -rw-r--r-- | html/app/config/app_constants.php | 39 |
1 files changed, 34 insertions, 5 deletions
diff --git a/html/app/config/app_constants.php b/html/app/config/app_constants.php index a89cc6a..4ddf7ac 100644 --- a/html/app/config/app_constants.php +++ b/html/app/config/app_constants.php @@ -1,11 +1,40 @@ <?php +// Contents +// Central Defaults (name) +// Default Values (user-privileges and user-roles) + + +// read ini file id exist +// --- -- -- - - - +if (file_exists("../core/auth/.env")) { + $env = parse_ini_file("../core/auth/.env"); +} + + // CENTRAL DEFAULTS //////////////////////////////////////////////////////////// // ----------------------------------------------------------------------------- +// NOTE: +// if .env file exists ... do not touch anything +// else ... replace $env[*] values with your setup + +// WEB-APP name and url +// --- -- -- - - - define('SITE_TITLE', 'Classroom'); -define('NO_REPLY_EMAIL', 'noreply@roptron.gr'); -define('REPLY_TO_EMAIL', 'noreply@roptron.gr'); +define('SITE_URL', 'http://localhost'); + +// email setup +// --- -- -- - - - +define('MAIL_MAILER', $env['MAIL_MAILER']); +define('MAIL_HOST', $env['MAIL_HOST']); +define('MAIL_PORT', $env['MAIL_PORT']); +define('MAIL_USERNAME', $env['MAIL_USERNAME']); +define('MAIL_PASSWORD', $env['MAIL_PASSWORD']); +define('MAIL_ENCRYPTION', $env['MAIL_ENCRYPTION']); +define('NO_REPLY_EMAIL', $env['NO_REPLY_EMAIL']); +define('REPLY_TO_EMAIL', $env['REPLY_TO_EMAIL']); + // DEFAULT VALUES ////////////////////////////////////////////////////////////// @@ -13,15 +42,15 @@ define('REPLY_TO_EMAIL', 'noreply@roptron.gr'); // default privileges (for the subscribed user) // (array of privilege aliases) -// --- +// --- -- -- - - - define('DEFAULT_PRIVILEGES', [ 'e.1', // economics, level 1 'p.1' // programming. level 1 ]); - - +// User Roles +// --- -- -- - - - define('READER', 1); define('EDITOR', 2); define('ADMIN', 3); |
