36 lines
1.0 KiB
PHP
36 lines
1.0 KiB
PHP
<?php
|
|
/*
|
|
* CASS_Config - Configuration of plugin
|
|
*
|
|
* This class is used to configure parameters of the plugin
|
|
*/
|
|
class CASS_Config
|
|
{
|
|
public static function execute()
|
|
{
|
|
//Configuration of plugin
|
|
define("PRODUCTION", true);
|
|
define("DB_DROP_IF_UNINSTALL", false);
|
|
|
|
//Recaptcha v2 key
|
|
//Not set because not work --> Directly in the code
|
|
define("RECAPTCHA_V2_KEY_SERVER", "");
|
|
define("RECAPTCHA_V2_KEY_CLIENT", "");
|
|
|
|
//Configuration of plugin
|
|
if (PRODUCTION) {
|
|
ini_set('display_errors', 'Off');
|
|
ini_set('error_reporting', E_ALL);
|
|
} else {
|
|
define("CASS_DISABLED_PHP_CACHE", true);
|
|
ini_set('error_reporting', E_ERROR || E_PARSE);
|
|
ini_set('display_errors', 'off');
|
|
ini_set('error_reporting', E_ALL);
|
|
define('WP_DEBUG', true);
|
|
define('WP_DEBUG_DISPLAY', true);
|
|
if (CASS_DISABLED_PHP_CACHE) {
|
|
Opcache_reset();
|
|
}
|
|
}
|
|
}
|
|
} |