| 1 |
<?php defined( 'ABSPATH' ) or die; |
| 2 |
|
| 3 |
$basepath = dirname( __FILE__ ) . DIRECTORY_SEPARATOR; |
| 4 |
|
| 5 |
$debug = false; |
| 6 |
if ( isset( $_GET['debug'] ) && $_GET['debug'] == 'true' ) { |
| 7 |
$debug = true; |
| 8 |
} |
| 9 |
|
| 10 |
$debug = true; |
| 11 |
|
| 12 |
$customify_config = require $basepath . 'customify_config.php'; |
| 13 |
|
| 14 |
return array( |
| 15 |
'plugin-name' => 'pixcustomify', |
| 16 |
'settings-key' => 'pixcustomify_settings', |
| 17 |
'textdomain' => 'customify', |
| 18 |
'template-paths' => array( |
| 19 |
$basepath . 'core/views/form-partials/', |
| 20 |
$basepath . 'views/form-partials/', |
| 21 |
), |
| 22 |
'fields' => array( |
| 23 |
'hiddens' => include 'settings/hiddens' . EXT, |
| 24 |
'general' => include 'settings/general' . EXT, |
| 25 |
'output' => include 'settings/output' . EXT, |
| 26 |
'typography' => include 'settings/typography' . EXT, |
| 27 |
'css_editor' => include 'settings/css_editor' . EXT, |
| 28 |
), |
| 29 |
'processor' => array( |
| 30 |
// callback signature: (array $input, customifyProcessor $processor) |
| 31 |
'preupdate' => array( |
| 32 |
// callbacks to run before update process |
| 33 |
// cleanup and validation has been performed on data |
| 34 |
), |
| 35 |
// 'postupdate' => array( |
| 36 |
// 'save_settings' |
| 37 |
// ), |
| 38 |
), |
| 39 |
'cleanup' => array( |
| 40 |
'switch' => array( 'switch_not_available' ), |
| 41 |
), |
| 42 |
'checks' => array( |
| 43 |
'counter' => array( 'is_numeric', 'not_empty' ), |
| 44 |
), |
| 45 |
'errors' => array( |
| 46 |
'not_empty' => __( 'Invalid Value.', 'customify' ), |
| 47 |
), |
| 48 |
// 'callbacks' => array( |
| 49 |
// 'save_settings' => 'save_customizer_plugin_settings' |
| 50 |
// ), |
| 51 |
// shows exception traces on error |
| 52 |
'debug' => $debug, |
| 53 |
|
| 54 |
/** |
| 55 |
* DEFAULTS - The default plugin options |
| 56 |
*/ |
| 57 |
'default_options' => array( |
| 58 |
|
| 59 |
) |
| 60 |
|
| 61 |
); # config |
| 62 |
|