re-add old IDNA class so we do not have to force the php-5.6 requirement for froxlor
Signed-off-by: Michael Kaufmann (d00p) <d00p@froxlor.org>
This commit is contained in:
@@ -114,7 +114,7 @@ return array(
|
|||||||
'varname' => 'letsencryptstate',
|
'varname' => 'letsencryptstate',
|
||||||
'type' => 'string',
|
'type' => 'string',
|
||||||
'string_emptyallowed' => false,
|
'string_emptyallowed' => false,
|
||||||
'default' => 'Germany',
|
'default' => 'Hessen',
|
||||||
'save_method' => 'storeSettingField',
|
'save_method' => 'storeSettingField',
|
||||||
),
|
),
|
||||||
'system_letsencryptchallengepath' => array(
|
'system_letsencryptchallengepath' => array(
|
||||||
|
|||||||
@@ -908,7 +908,11 @@ class FroxlorInstall
|
|||||||
$content .= $this->_status_message('red', $this->_lng['requirements']['notfound'] . ' (' . PHP_VERSION . ')');
|
$content .= $this->_status_message('red', $this->_lng['requirements']['notfound'] . ' (' . PHP_VERSION . ')');
|
||||||
$_die = true;
|
$_die = true;
|
||||||
} else {
|
} else {
|
||||||
$content .= $this->_status_message('green', PHP_VERSION);
|
if (version_compare("5.6.0", PHP_VERSION, ">=")) {
|
||||||
|
$content .= $this->_status_message('orange', $this->_lng['requirements']['newerphpprefered'] . ' (' .PHP_VERSION . ')');
|
||||||
|
} else {
|
||||||
|
$content .= $this->_status_message('green', PHP_VERSION);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check if magic_quotes_runtime is active | get_magic_quotes_runtime() is always FALSE since 5.4
|
// Check if magic_quotes_runtime is active | get_magic_quotes_runtime() is always FALSE since 5.4
|
||||||
|
|||||||
@@ -24,6 +24,7 @@ $lng['requirements']['notfound'] = 'not found';
|
|||||||
$lng['requirements']['notinstalled'] = 'not installed';
|
$lng['requirements']['notinstalled'] = 'not installed';
|
||||||
$lng['requirements']['activated'] = 'enabled';
|
$lng['requirements']['activated'] = 'enabled';
|
||||||
$lng['requirements']['phpversion'] = 'PHP version >= 5.3';
|
$lng['requirements']['phpversion'] = 'PHP version >= 5.3';
|
||||||
|
$lng['requirements']['newerphpprefered'] = 'Good, but php-5.6 is prefered.';
|
||||||
$lng['requirements']['phpmagic_quotes_runtime'] = 'magic_quotes_runtime...';
|
$lng['requirements']['phpmagic_quotes_runtime'] = 'magic_quotes_runtime...';
|
||||||
$lng['requirements']['phpmagic_quotes_runtime_description'] = 'PHP setting "magic_quotes_runtime" must be set to "Off". We have disabled it temporary for now please fix the coresponding php.ini.';
|
$lng['requirements']['phpmagic_quotes_runtime_description'] = 'PHP setting "magic_quotes_runtime" must be set to "Off". We have disabled it temporary for now please fix the coresponding php.ini.';
|
||||||
$lng['requirements']['phppdo'] = 'PHP PDO extension and PDO-MySQL driver...';
|
$lng['requirements']['phppdo'] = 'PHP PDO extension and PDO-MySQL driver...';
|
||||||
|
|||||||
@@ -24,6 +24,7 @@ $lng['requirements']['notfound'] = 'nicht gefunden';
|
|||||||
$lng['requirements']['notinstalled'] = 'nicht installiert';
|
$lng['requirements']['notinstalled'] = 'nicht installiert';
|
||||||
$lng['requirements']['activated'] = 'ist aktiviert.';
|
$lng['requirements']['activated'] = 'ist aktiviert.';
|
||||||
$lng['requirements']['phpversion'] = 'PHP Version >= 5.3';
|
$lng['requirements']['phpversion'] = 'PHP Version >= 5.3';
|
||||||
|
$lng['requirements']['newerphpprefered'] = 'Passt, aber php-5.6 wird bevorzugt.';
|
||||||
$lng['requirements']['phpmagic_quotes_runtime'] = 'magic_quotes_runtime';
|
$lng['requirements']['phpmagic_quotes_runtime'] = 'magic_quotes_runtime';
|
||||||
$lng['requirements']['phpmagic_quotes_runtime_description'] = 'Die PHP Einstellung "magic_quotes_runtime" muss deaktiviert sein ("Off"). Die Einstellung wurde temporär deaktiviert, bitte ändern Sie diese in der entsprechenden php.ini.';
|
$lng['requirements']['phpmagic_quotes_runtime_description'] = 'Die PHP Einstellung "magic_quotes_runtime" muss deaktiviert sein ("Off"). Die Einstellung wurde temporär deaktiviert, bitte ändern Sie diese in der entsprechenden php.ini.';
|
||||||
$lng['requirements']['phppdo'] = 'PHP PDO Erweiterung und PDO-MySQL Treiber...';
|
$lng['requirements']['phppdo'] = 'PHP PDO Erweiterung und PDO-MySQL Treiber...';
|
||||||
|
|||||||
3464
lib/classes/idna/class.idna_convert.php
Normal file
3464
lib/classes/idna/class.idna_convert.php
Normal file
File diff suppressed because it is too large
Load Diff
@@ -39,10 +39,12 @@ class idna_convert_wrapper
|
|||||||
public function __construct()
|
public function __construct()
|
||||||
{
|
{
|
||||||
// Instantiate it
|
// Instantiate it
|
||||||
//$this->idna_converter = new idna_convert(array('idn_version' => '2008', 'encode_german_sz' => false));
|
if (version_compare("5.6.0", PHP_VERSION, ">=")) {
|
||||||
|
$this->idna_converter = new idna_convert(array('idn_version' => '2008', 'encode_german_sz' => false));
|
||||||
// use this when using new version of IdnaConverter (which does not work yet)
|
} else {
|
||||||
$this->idna_converter = new Mso\IdnaConvert\IdnaConvert();
|
// use this when using new version of IdnaConverter (which does not work yet)
|
||||||
|
$this->idna_converter = new Mso\IdnaConvert\IdnaConvert();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -57,9 +59,12 @@ class idna_convert_wrapper
|
|||||||
|
|
||||||
public function encode($to_encode)
|
public function encode($to_encode)
|
||||||
{
|
{
|
||||||
$to_encode = $this->is_utf8($to_encode) ? $to_encode : utf8_encode($to_encode);
|
if (version_compare("5.6.0", PHP_VERSION, ">=")) {
|
||||||
return $this->idna_converter->encode($to_encode);
|
return $this->_do_action('encode', $to_encode);
|
||||||
//return $this->_do_action('encode', $to_encode);
|
} else {
|
||||||
|
$to_encode = $this->is_utf8($to_encode) ? $to_encode : utf8_encode($to_encode);
|
||||||
|
return $this->idna_converter->encode($to_encode);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -74,8 +79,11 @@ class idna_convert_wrapper
|
|||||||
|
|
||||||
public function decode($to_decode)
|
public function decode($to_decode)
|
||||||
{
|
{
|
||||||
return $this->idna_converter->decode($to_decode);
|
if (version_compare("5.6.0", PHP_VERSION, ">=")) {
|
||||||
//return $this->_do_action('decode', $to_decode);
|
return $this->_do_action('decode', $to_decode);
|
||||||
|
} else {
|
||||||
|
return $this->idna_converter->decode($to_decode);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user