add clear
This commit is contained in:
@@ -36,17 +36,17 @@ class Help extends Miniprogarampage
|
|||||||
*/
|
*/
|
||||||
private static function xmlChild(array $array)
|
private static function xmlChild(array $array)
|
||||||
{
|
{
|
||||||
$= '';
|
$string = '';
|
||||||
foreach ($array as $key => $value) {
|
foreach ($array as $key => $value) {
|
||||||
if (is_array($value)) {
|
if (is_array($value)) {
|
||||||
$.= static::xmlChild($value);
|
$string .= static::xmlChild($value);
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (is_numeric($value)) {
|
if (is_numeric($value)) {
|
||||||
$.= "<" . $key . ">" . $value . "</" . $key . ">";
|
$string .= "<" . $key . ">" . $value . "</" . $key . ">";
|
||||||
} else {
|
} else {
|
||||||
$.= "<" . $key . "><![CDATA[" . $value . "]]></" . $key . ">";
|
$string .= "<" . $key . "><![CDATA[" . $value . "]]></" . $key . ">";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return $string;
|
return $string;
|
||||||
@@ -163,7 +163,7 @@ class Help extends Miniprogarampage
|
|||||||
public static function sign(array $array, $key, $type)
|
public static function sign(array $array, $key, $type)
|
||||||
{
|
{
|
||||||
ksort($array, SORT_ASC);
|
ksort($array, SORT_ASC);
|
||||||
$= [];
|
$string = [];
|
||||||
foreach ($array as $hashKey => $val) {
|
foreach ($array as $hashKey => $val) {
|
||||||
if (empty($val)) {
|
if (empty($val)) {
|
||||||
continue;
|
continue;
|
||||||
@@ -171,7 +171,7 @@ class Help extends Miniprogarampage
|
|||||||
$string[] = $hashKey . '=' . $val;
|
$string[] = $hashKey . '=' . $val;
|
||||||
}
|
}
|
||||||
$string[] = 'key=' . $key;
|
$string[] = 'key=' . $key;
|
||||||
$= implode('&', $string);
|
$string = implode('&', $string);
|
||||||
if ($type == 'MD5') {
|
if ($type == 'MD5') {
|
||||||
return strtoupper(md5($string));
|
return strtoupper(md5($string));
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user