| Copyright: See the COPYRIGHT.txt file. | | License: GPLv2 or later, see the LICENSE.txt file. | +---------------------------------------------------------------------------+ */ // Require the initialisation file require_once '../../init.php'; // Required files require_once MAX_PATH . '/lib/OA/Admin/Option.php'; require_once MAX_PATH . '/lib/OA/Admin/UI/UserAccess.php'; require_once MAX_PATH . '/lib/max/Admin/Languages.php'; require_once MAX_PATH . '/lib/max/Plugin/Translation.php'; require_once MAX_PATH . '/www/admin/config.php'; // Security check OA_Permission::enforceAccount(OA_ACCOUNT_ADMIN, OA_ACCOUNT_MANAGER, OA_ACCOUNT_ADVERTISER, OA_ACCOUNT_TRAFFICKER); // Create a new option object for displaying the setting's page's HTML form $oOptions = new OA_Admin_Option('user'); // Prepare an array for storing error messages $aErrormessage = array(); // If the settings page is a submission, deal with the form data if (isset($_POST['submitok']) && $_POST['submitok'] == 'true') { // Register input variables phpAds_registerGlobalUnslashed('pwold', 'pw', 'pw2'); // Get the DB_DataObject for the current user $doUsers = OA_Dal::factoryDO('users'); $doUsers->get(OA_Permission::getUserId()); // Set defaults $changePassword = false; // Get the current authentication plugin instance $oPlugin = OA_Auth::staticGetAuthPlugin(); // Check password if (!isset($pwold) || !$oPlugin->checkPassword(OA_Permission::getUsername(), $pwold)) {
| License: GPLv2 or later, see the LICENSE.txt file. | +---------------------------------------------------------------------------+ */ // Require the initialisation file require_once '../../init.php'; // Required files require_once MAX_PATH . '/lib/OA/Admin/Option.php'; require_once MAX_PATH . '/lib/OA/Admin/Settings.php'; require_once MAX_PATH . '/lib/max/Plugin/Translation.php'; require_once MAX_PATH . '/www/admin/config.php'; require_once MAX_PATH . '/lib/OA/Admin/TemplatePlugin.php'; require_once LIB_PATH . '/Plugin/ComponentGroupManager.php'; // Security check OA_Permission::enforceAccount(OA_ACCOUNT_ADMIN); // Create a new option object for displaying the setting's page's HTML form $oOptions = new OA_Admin_Option('preferences'); // Prepare an array for storing error messages $aErrormessage = array(); $pattern = '/[^a-zA-Z0-9\\._-]/'; $plugin = preg_replace($pattern, '', $_REQUEST['parent']); $group = preg_replace($pattern, '', $_REQUEST['group']); $parent = preg_replace($pattern, '', $_REQUEST['parent']); if ($plugin) { $backURL = "plugin-index.php?action=info&package={$plugin}"; } else { $backURL = "plugin-index.php?selection=plugins"; } // get the settings for this plugin $oManager =& new OX_Plugin_ComponentGroupManager(); $aConfig = $oManager->_getComponentGroupConfiguration($group); // If the settings page is a submission, deal with the form data
/** * Test pearLogPriorityToConstrantName function * */ function test_pearLogPriorityToConstrantName() { $oOption = new OA_Admin_Option('settings'); $this->assertEqual('PEAR_LOG_CRIT', $oOption->pearLogPriorityToConstrantName(PEAR_LOG_CRIT)); $this->assertEqual('PEAR_LOG_INFO', $oOption->pearLogPriorityToConstrantName('PEAR_LOG_INFO')); }
| Copyright: See the COPYRIGHT.txt file. | | License: GPLv2 or later, see the LICENSE.txt file. | +---------------------------------------------------------------------------+ */ // Require the initialisation file require_once '../../init.php'; // Required files require_once MAX_PATH . '/lib/OA/Admin/Option.php'; require_once MAX_PATH . '/lib/OA/Admin/UI/UserAccess.php'; require_once MAX_PATH . '/lib/max/Plugin/Translation.php'; require_once MAX_PATH . '/www/admin/config.php'; require_once MAX_PATH . '/lib/RV/Admin/Languages.php'; // Security check OA_Permission::enforceAccount(OA_ACCOUNT_ADMIN, OA_ACCOUNT_MANAGER, OA_ACCOUNT_ADVERTISER, OA_ACCOUNT_TRAFFICKER); // Create a new option object for displaying the setting's page's HTML form $oOptions = new OA_Admin_Option('user'); // Prepare an array for storing error messages $aErrormessage = array(); // If the settings page is a submission, deal with the form data if (isset($_POST['submitok']) && $_POST['submitok'] == 'true') { // Register input variables phpAds_registerGlobalUnslashed('contact_name', 'language'); // Get the DB_DataObject for the current user $doUsers = OA_Dal::factoryDO('users'); $doUsers->get(OA_Permission::getUserId()); // Get the current authentication plugin instance $oPlugin = OA_Auth::staticGetAuthPlugin(); if (isset($contact_name)) { $doUsers->contact_name = $contact_name; } if (isset($language)) {
*/ // Require the initialisation file require_once '../../init.php'; // Required files require_once MAX_PATH . '/lib/OA/Admin/Option.php'; require_once MAX_PATH . '/lib/OA/Preferences.php'; require_once MAX_PATH . '/lib/max/Plugin/Translation.php'; require_once MAX_PATH . '/www/admin/config.php'; require_once LIB_PATH . '/Plugin/ComponentGroupManager.php'; // Security check OA_Permission::enforceAccount(OA_ACCOUNT_ADMIN, OA_ACCOUNT_MANAGER, OA_ACCOUNT_ADVERTISER, OA_ACCOUNT_TRAFFICKER); phpAds_registerGlobal('group'); // Load the account's preferences, with additional information, into a specially named array $GLOBALS['_MAX']['PREF_EXTRA'] = OA_Preferences::loadPreferences(true, true); // Create a new option object for displaying the setting's page's HTML form $oOptions = new OA_Admin_Option('preferences'); // Prepare an array for storing error messages $aErrormessage = array(); $oComponentGroupManager = new OX_Plugin_ComponentGroupManager(); $aGroup = $oComponentGroupManager->_getComponentGroupConfiguration($group); $enabled = $GLOBALS['_MAX']['CONF']['pluginGroupComponents'][$group]; $disabled = !$enabled && OA_Permission::getAccountType() != OA_ACCOUNT_ADMIN; // If the settings page is a submission, deal with the form data if (isset($_POST['submitok']) && $_POST['submitok'] == 'true') { // Prepare an array of the HTML elements to process, and which // of the preferences are checkboxes $aElements = array(); foreach ($aGroup['preferences'] as $k => $v) { $aElements[] = $group . '_' . $v['name']; // Register the HTML element value MAX_commonRegisterGlobalsArray(array($group . '_' . $v['name']));
+---------------------------------------------------------------------------+ $Id: account-preferences-tracker.php 37157 2009-05-28 12:31:10Z andrew.hill $ */ // Require the initialisation file require_once '../../init.php'; // Required files require_once MAX_PATH . '/lib/OA/Admin/Option.php'; require_once MAX_PATH . '/lib/OA/Preferences.php'; require_once MAX_PATH . '/lib/max/Plugin/Translation.php'; require_once MAX_PATH . '/www/admin/config.php'; // Security check OA_Permission::enforceAccount(OA_ACCOUNT_ADMIN, OA_ACCOUNT_MANAGER, OA_ACCOUNT_TRAFFICKER, OA_ACCOUNT_ADVERTISER); // Load the account's preferences, with additional information, into a specially named array $GLOBALS['_MAX']['PREF_EXTRA'] = OA_Preferences::loadPreferences(true, true); // Create a new option object for displaying the setting's page's HTML form $oOptions = new OA_Admin_Option('preferences'); // Prepare an array for storing error messages $aErrormessage = array(); // If the settings page is a submission, deal with the form data if (isset($_POST['submitok']) && $_POST['submitok'] == 'true') { // Prepare an array of the HTML elements to process, and which // of the preferences are checkboxes $aElements = array(); $aCheckboxes = array(); // Tracker $aElements[] = 'tracker_default_status'; $aElements[] = 'tracker_default_type'; $aElements[] = 'tracker_link_campaigns'; $aCheckboxes['tracker_link_campaigns'] = true; // Save the preferences $result = OA_Preferences::processPreferencesFromForm($aElements, $aCheckboxes);
+---------------------------------------------------------------------------+ $Id: plugin-settings.php 37157 2009-05-28 12:31:10Z andrew.hill $ */ // Require the initialisation file require_once '../../init.php'; // Required files require_once MAX_PATH . '/lib/OA/Admin/Option.php'; require_once MAX_PATH . '/lib/OA/Admin/Settings.php'; require_once MAX_PATH . '/lib/max/Plugin/Translation.php'; require_once MAX_PATH . '/www/admin/config.php'; require_once MAX_PATH . '/lib/OA/Admin/TemplatePlugin.php'; require_once LIB_PATH . '/Plugin/ComponentGroupManager.php'; // Security check OA_Permission::enforceAccount(OA_ACCOUNT_ADMIN); // Create a new option object for displaying the setting's page's HTML form $oOptions = new OA_Admin_Option('settings'); // Prepare an array for storing error messages $aErrormessage = array(); $group = $_REQUEST['group']; $plugin = $_REQUEST['plugin']; if ($plugin) { $backURL = "plugin-index.php?action=info&package={$plugin}"; } else { $backURL = "plugin-index.php?selection=plugins"; } // get the settings for this plugin $oManager =& new OX_Plugin_ComponentGroupManager(); $aComponentSettings = $oManager->getComponentGroupSettings($group, true); // If the settings page is a submission, deal with the form data if (isset($_POST['submitok']) && $_POST['submitok'] == 'true') { // Prepare an array of the HTML elements to process, and the
| along with this program; if not, write to the Free Software | | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | +---------------------------------------------------------------------------+ $Id: account-settings-debug.php 37157 2009-05-28 12:31:10Z andrew.hill $ */ // Require the initialisation file require_once '../../init.php'; // Required files require_once MAX_PATH . '/lib/OA/Admin/Option.php'; require_once MAX_PATH . '/lib/OA/Admin/Settings.php'; require_once MAX_PATH . '/lib/max/Plugin/Translation.php'; require_once MAX_PATH . '/www/admin/config.php'; // Security check OA_Permission::enforceAccount(OA_ACCOUNT_ADMIN); // Create a new option object for displaying the setting's page's HTML form $oOptions = new OA_Admin_Option('settings'); $prefSection = "debug"; // Prepare an array for storing error messages $aErrormessage = array(); // If the settings page is a submission, deal with the form data if (isset($_POST['submitok']) && $_POST['submitok'] == 'true') { // Prepare an array of the HTML elements to process, and the // location to save the values in the settings configuration // file $aElements = array(); // Audit Trail $aElements += array('audit_enabled' => array('audit' => 'enabled', 'bool' => true), 'audit_enabledForZoneLinking' => array('audit' => 'enabledForZoneLinking', 'bool' => true)); // Debug Logging Settings $aElements += array('debug_production' => array('debug' => 'production', 'bool' => true), 'log_enabled' => array('log' => 'enabled', 'bool' => true), 'log_methodNames' => array('log' => 'methodNames', 'bool' => true), 'log_lineNumbers' => array('log' => 'lineNumbers', 'bool' => true), 'log_type' => array('log' => 'type'), 'log_name' => array('log' => 'name'), 'log_priority' => array('log' => 'priority'), 'log_ident' => array('log' => 'ident'), 'log_paramsUsername' => array('log' => 'paramsUsername'), 'log_paramsPassword' => array('log' => 'paramsPassword')); // Create a new settings object, and save the settings! $oSettings = new OA_Admin_Settings();