Services\Installer::checkCompatibility PHP Method

checkCompatibility() public method

Check whether or not, the current PHP installation is compatible with the requirements or not
public checkCompatibility ( )
    public function checkCompatibility()
    {
        if (!version_compare(phpversion(), '5.5.9', '>=')) {
            return $this->listener->installerFails('PHP version must be at least 5.5.9');
        }
        $required_extensions = array('fileinfo', 'curl', 'zip', 'openssl', 'mbstring', 'tokenizer');
        foreach ($required_extensions as $extension) {
            if (!extension_loaded($extension)) {
                return $this->listener->installerFails("{$extension} PHP Extension must be enabled");
            }
        }
    }