Prints a list of the configuration settings read from <i>php.ini</i>

@access public
@static
485255
public static function phpini()
    {
        // disabled
        if (!static::_debug()) {
            return false;
        }

        if (!is_readable(get_cfg_var('cfg_file_path'))) {
            return false;
        }

        // render it
        static::heading("This is a list of the configuration settings read from ", get_cfg_var('cfg_file_path'), ".");

        return static::dump(parse_ini_file(get_cfg_var('cfg_file_path'), true));
    }
1061192
def config():
    ''''''
    if hasattr(current_app, 'settings_file'):
        log.info('Loaded configuration from %s', current_app.settings_file)

    log.info(white('Current configuration'))
    for key in sorted(current_app.config):
        if key.startswith('__') or not key.isupper():
            continue
        echo('{0}: {1}'.format(white(key), current_app.config[key]))
333912
private function getListSettings()
    {
        $settingsStorage = $this->getSettingsStorage();
        if (!$settingsStorage->exists(CspHeaderSettingsInterface::CSP_HEADER_LIST)) {
            return [];
        }

        return json_decode($settingsStorage->get(CspHeaderSettingsInterface::CSP_HEADER_LIST));
    }
285834
public static function listConfig() {
		if( static::$configs !== null ) {
			return static::$configs;
		}
		$cache = new APCache('sqladapter', 'db_configs', 2*3600);
		if( !$cache->get($configs) ) {
			$fileCconfig = IniConfig::build(DBCONF, true, false)->all;
			$configs	= array();
			foreach( $fileCconfig as $key => $value ) {
				if( is_array($value) ) {
					// Instance config
					$configs[$key]	= $value;
					
				} else {
					// Instance config property
					if( !isset($configs['default']) ) {
						$configs['default']	= array();
					}
					$configs['default'][$key] = $value;
				}
			}
			$cache->set($configs);
		}
		return static::$configs = $configs;
	}
1308327
public function renderSettings()
    {

        $result = View::render_view( 'base/ilab-settings.php', [
            'title'=>$this->toolInfo['settings']['title'],
            'group'=>$this->options_group,
            'page'=>$this->options_page
        ]);

        $result = str_replace('<th scope="row">__CUSTOMREMOVE__</th>', '', $result);

        echo $result;
    }
767550
function printResults()
    {
        $results = $this->resultList();
        foreach ( $results as $result )
        {
            $this->display( $result );
        }
    }
382865
protected function readConfig() {
		$file = $this->path->getConfigPath() . '/session.php';

		if (file_exists($file)) {
			$config = require($file);
			$this->enabled = true;

			if (isset($config['options']) && is_array($config['options'])) {
				$this->startOptions = $config['options'];
			}
		}
	}
929636
public static function checkSettings()
    {
        if (version_compare(PHP_VERSION, '6.0.0', '<') && ini_get('safe_mode')) {
            Debug::_warn(
                '<a target="_blank" href="http://www.php.net/manual/en/features.safe-mode.php">safe_mode</a> is on'
                .( ini_get('safe_mode_gid') ? ' / safe_mode_gid = '.ini_get('safe_mode_gid') : '' )
            );
        }
        if (ini_get('default_charset') == '') {
            Debug::_info('default_charset not set&hellip; setting to UTF-8');
            // this will also set default Content-Type header to 'Content-Type: text/html; charset=UTF-8'
            ini_set('default_charset', 'UTF-8');
        }
        if (!extension_loaded('mbstring')) {
            Debug::_warn('mbstring extension not loaded');
        } elseif (ini_get('mb_string.internal_encoding') == '') {
            Debug::_info('mb_string.internal_encoding not set&hellip;');
            $defaultCharset = ini_get('default_charset');
            Debug::_info(' setting to default_charset: '.$defaultCharset);
            mb_internal_encoding($defaultCharset);
            mb_regex_encoding($defaultCharset);
        }
    }
130026
public function printUsage() {
        $commandList = [];

        foreach ($this->config['commands'] as $command => $commandOptions) {
            $separator = 20 - strlen($command);

            $commandList[] = '    ' . $command . str_pad(' ', $separator) .
                '<dim>' . $commandOptions['description'] . '</dim>';
        }

        sort($commandList);

        $this->log->info(
            <<< EOF
%1\$s: %3\$s

<strong>VERSION</strong>
    %4\$s

<strong>USAGE</strong>
    \$ %1\$s [COMMAND] [OPTIONS]

<strong>COMMANDS</strong>
%2\$s

    <dim># Print usage of a command:</dim>
    \$ %1\$s help COMMAND
    <dim># or:</dim>
    \$ %1\$s COMMAND --help
    <dim># List all commands:</dim>
    \$ %1\$s list

<strong>COMMON OPTIONS</strong>
    -c <u>FILE</u>,            <dim>Include settings stored in a JSON-formatted</dim>
    --config=<u>FILE</u>       <dim>configuration file FILE; repeat option for more</dim>
                        <dim>than one FILE</dim>
    -s <u>KEY=VALUE</u>,       <dim>Add runtime setting KEY with its VALUE; separate</dim>
    --setting=<u>KEY=VALUE</u> <dim>nested keys with ".", for example "key1.key2=123";</dim>
                        <dim>repeat option for more than one KEY</dim>

    --no-colors         <dim>Do not print colored messages</dim>
    -q, --quiet         <dim>Do not output messages, only errors</dim>
    -v, --verbose       <dim>Be more verbose</dim>

    -h, --help          <dim>Print this help or information about a</dim>
                        <dim>specific command</dim>
    --version           <dim>Print version information</dim>

<strong>FIRST STEPS</strong>
    <dim># %5\$s:</dim>
    %1\$s init
    <dim># %6\$s:</dim>
    %1\$s configtest
EOF
            ,
            $this->config['composer']['extra']['name'],
            implode(PHP_EOL, $commandList),
            $this->config['composer']['description'],
            $this->config['composer']['extra']['version'],
            $this->config['commands']['init']['description'],
            $this->config['commands']['configtest']['description']
        );

        return $this;
    }
877655
function readINISettings()
    {
        $this->readImageHandlersFromINI();
        $this->readSupportedFormatsFromINI();
        $this->readImageAliasesFromINI();
        $this->readMIMETypeSettingsFromINI();
        $this->readMIMETypeQualitySettingFromINI();
        $this->readConversionRuleSettingsFromINI();
    }
533670
public function configureSettings()
    {
        // If no settings && sections, return.
        $settings = $this->repository()->getSettings();
        $sections = $this->repository()->getSections();

        if ($settings->isEmpty() && $sections->isEmpty()) {
            return;
        }

        // Configure sections.
        $sections->each(function ($section) {
            /** @var SectionInterface $section */
            add_settings_section($section->getId(), $section->getTitle(), [$this, 'renderSections'], $this->getSlug());
        });

        // Configure settings.
        foreach ($settings->all() as $slug => $fields) {
            foreach ($fields as $setting) {
                $setting = $this->prepareSetting($setting);

                // Display the setting.
                add_settings_field(
                    $setting->getName(),
                    $setting->getOption('label'),
                    [$this, 'renderSettings'],
                    $this->getSlug(),
                    $slug,
                    $setting
                );

                // Validate setting.
                $showInRest = $this->isShownInRest();

                if ($setting->getOption('show_in_rest', false)) {
                    $showInRest = true;
                }

                register_setting($this->getSlug(), $setting->getName(), [
                    'sanitize_callback' => [$this, 'sanitizeSetting'],
                    'default' => $setting->getOption('data', ''),
                    'show_in_rest' => $showInRest,
                    'type' => $setting->getOption('data_type', 'string')
                ]);
            }
        }
    }
1074351
private static function readKeys(): void
    {
        static::$keys = [];

        foreach (ini_get_all() as $key => $value) {
            static::$keys[$key] = $value['access'] === 1 /* user */ || $value['access'] === 7 /* all */;
        }
    }
1136539
private static function init() {
        static $initialized = false;
        if ($initialized) return;

        /** @var ConfigInterface $config */
        $config = self::di('config');

        // (1) Get the application's default loglevel configuration (fall back to the built-in default).
        $logLevel = $config->get('log.level', '');
        if (is_array($logLevel))
            $logLevel = isset($logLevel['']) ? $logLevel[''] : '';
        $logLevel = self::logLevelToId($logLevel) ?: self::DEFAULT_LOGLEVEL;
        self::$appLogLevel = $logLevel;


        // (2) mail handler: enabled if mail receivers are configured
        $receivers = [];
        foreach (explode(',', $config->get('log.mail.receiver', '')) as $receiver) {
            if ($receiver = trim($receiver)) {
                if (filter_var($receiver, FILTER_VALIDATE_EMAIL)) {         // silently skip invalid addresses
                    $receivers[] = $receiver;
                }
            }
        }
        self::$mailHandler   = (bool) $receivers;
        self::$mailReceivers =        $receivers;


        // (3) L_FATAL print handler: enabled on local/white-listed access or if explicitely enabled
        self::$printFatalHandler = CLI || Application::isAdminIP() || ini_get_bool('display_errors');


        // (4) non L_FATAL print handler: enabled on local access, if explicitely enabled or if the mail handler is disabled
        self::$printNonfatalHandler = CLI || in_array($_SERVER['REMOTE_ADDR'], ['127.0.0.1', $_SERVER['SERVER_ADDR']])
                                          || ini_get_bool('display_errors')
                                          || (self::$printFatalHandler && !self::$mailHandler);

        // (5) SMS handler: enabled if SMS receivers are configured (operator settings are checked at log time)
        self::$smsReceivers = [];
        foreach (explode(',', $config->get('log.sms.receiver', '')) as $receiver) {
            if ($receiver=trim($receiver)) {
                if (strStartsWith($receiver, '+' )) $receiver = substr($receiver, 1);
                if (strStartsWith($receiver, '00')) $receiver = substr($receiver, 2);
                if (!ctype_digit($receiver)) {
                    self::log('Invalid SMS receiver configuration: "'.$receiver.'"', L_WARN, ['class'=>__CLASS__, 'file'=>__FILE__, 'line'=>__LINE__]);
                    continue;
                }
                self::$smsReceivers[] = $receiver;
            }
        }
        $logLevel = $config->get('log.sms.level', self::$appLogLevel);
        if (is_string($logLevel))                                   // a string if configured
            $logLevel = self::logLevelToId($logLevel) ?: self::$appLogLevel;
        self::$smsLogLevel = $logLevel;

        $options = $config->get('sms', []);
        if (!is_array($options)) throw new IllegalTypeException('Invalid type of config value "sms": '.gettype($options).' (not array)');
        self::$smsOptions = $options;

        self::$smsHandler = self::$smsReceivers && self::$smsOptions;


        // (6) PHP error_log handler: enabled if the mail handler is disabled
        self::$errorLogHandler = !self::$mailHandler;

        $initialized = true;
    }
486411
public function printSummary() {
    drush_print();

    // Print env files used for this definition.
    drush_print($this->formatHeading('Environment Definitions Found'));
    foreach ($this->loadedEnvs as $filename) {
      drush_print("{$filename}", 1);
    }

    drush_print();
    drush_print($this->formatHeading(dt("CONFIGURATION SUMMARY")));

    // We want to make sure they are printed in the same order as they will run.
    foreach ($this->getActiveDefinition() as $group => $options) {
      // Print a nice heading.
      $heading = $this->formatHeading($group);

      switch (strtolower($group)) {
        case 'modules':
          $this->printModuleSummary($options, $heading);
          break;

        case 'variables':
          $this->printVariableSummary($options, $heading);
          break;

        case 'permissions':
          $this->printPermissionSummary($options, $heading);
          break;

        case 'commands':
          $this->printCommandSummary($options, $heading);
          break;

        default:
          drush_print($this->formatHeading($group));
          drush_log(dt("I'm not sure what to do with '@group'.", ['@group' => $group]), 'warning');
          break;
      }
    }
  }
382418
protected function setDataEditSettings()
    {
        $header = $this->getData('settings.header');

        if (is_array($header)) {

            $string = '';
            foreach ($header as $key => $value) {
                $string .= "$key $value" . PHP_EOL;
            }

            $this->setData('settings.header', trim($string));
        }
    }
1209530
public function list_settings()
    {
        if (!$this->is_loggedin) {
            return false;
        }

        $response = $this->exec_curl('/api/s/' . $this->site . '/get/setting');

        return $this->process_response($response);
    }
355829
public function initSettingsData()
    {
        $config = App::make('config');
        $this->locale = $config->get('app.locale', 'en');
        $this->fallback_locale = $this->getFallbackLocale($this->locale);
        $this->timezone = $config->get('cms.backendTimezone', $config->get('app.timezone'));

        $this->editor_font_size = $config->get('editor.font_size', 12);
        $this->editor_word_wrap = $config->get('editor.word_wrap', 'fluid');
        $this->editor_code_folding = $config->get('editor.code_folding', 'manual');
        $this->editor_tab_size = $config->get('editor.tab_size', 4);
        $this->editor_theme = $config->get('editor.theme', static::DEFAULT_THEME);
        $this->editor_show_invisibles = $config->get('editor.show_invisibles', false);
        $this->editor_highlight_active_line = $config->get('editor.highlight_active_line', true);
        $this->editor_use_hard_tabs = $config->get('editor.use_hard_tabs', false);
        $this->editor_show_gutter = $config->get('editor.show_gutter', true);
        $this->editor_auto_closing = $config->get('editor.auto_closing', false);
        $this->editor_autocompletion = $config->get('editor.editor_autocompletion', 'manual');
        $this->editor_enable_snippets = $config->get('editor.enable_snippets', false);
        $this->editor_display_indent_guides = $config->get('editor.display_indent_guides', false);
        $this->editor_show_print_margin = $config->get('editor.show_print_margin', false);
    }