Supported Versions: PHP 4, PHP 5, PHP 7, PHP 8
Decodes URL-encoded string
<?php urldecode(string $string): string
<?php         $cookies = [];

        foreach ($cookieParts as $cookiePart) {

            [$cookieName, $cookieValue] = explode('=', $cookiePart, 2);

            $cookies[$cookieName] = urldecode($cookieValue);

        }

        return $cookies;

    }