X-Git-Url: https://jasonwoof.com/gitweb/?a=blobdiff_plain;f=config.php;h=da021ef135bcbdbd864d8c7bcce54373591e6a26;hb=6dcd0cadcca91c18d12d9674e6ec3ce60cb44d31;hp=f5c078ef5f065069dfa71ea79b3d9d3fb00c593c;hpb=3b9b94e5e746542e8bacec485df87a265e7daeda;p=wfpl-cms.git diff --git a/config.php b/config.php index f5c078e..da021ef 100644 --- a/config.php +++ b/config.php @@ -9,6 +9,16 @@ define('WFPL_DB_PASS', 'fixme'); # CMS login passwords are stored in the database. See admin_users.php date_default_timezone_set('America/New_York'); +# If you change these, update style.styl too +define('WFPL_IMAGE_WIDTH_FULL', 900); +define('WFPL_IMAGE_WIDTH_SMALL', 336); # this is "sidebar_width" in style.styl +define('WFPL_IMAGE_WIDTH_THUMB', 70); +$GLOBALS['wfpl_image_widths'] = array( + WFPL_IMAGE_WIDTH_FULL, + WFPL_IMAGE_WIDTH_SMALL, + WFPL_IMAGE_WIDTH_THUMB +); + # Enable features, auto-includes require_once(DOCROOT . 'inc/wfpl/format.php'); require_once(DOCROOT . 'inc/wfpl/db.php'); @@ -19,3 +29,24 @@ require_once(DOCROOT . 'inc/misc.php'); # Connect to the database db_connect(WFPL_DB, WFPL_DB_USER, WFPL_DB_PASS); + +# upgrade db (only) on special trigger (assures only one upgrade at a time) +if (isset($_SERVER['HTTP_X_UPGRADE_DB_NOW'])) { + require_once(DOCROOT . 'inc/db_upgrade.php'); + db_upgrade(); +} + +$GLOBALS['email_templates'] = [ + 'backend_bug' => [ + 'title' => "Notification for site programmer(s)", + 'description' => "This email template is used if/when the back-end code of this site encounters an unusual/suspicious situation that it's not sure how to cope with.", + 'variables' => [ + ['message', "details about the unusual/suspicious situation"] + ], + 'subject' => "backend alert", + 'content' => "Hi developer,\n\nPlease investigate the following debugging message from the site:\n\n~message~" + 'from_addr' => 'noreply@example.com', + 'to_addr' => 'fixme@example.com' # not all templates need this field + ] + # ... +];