protected function arrayToHtml($content, $html = '')
    {
        // scalar types can be return directly
        if (is_scalar($content)) {
            return $content;
        }

        $html = "<ul>\n";

        // field name
        foreach ($content as $field => $value) {
            $html .= "<li><strong>" . $field . ":</strong> ";
            if (is_array($value)) {
                // recurse
                $html .= $this->arrayToHtml($value);
            } else {
                // value, with hyperlinked hyperlinks
                if (is_bool($value)) {
                    $value = $value ? 'true' : 'false';
                }
                $value = htmlentities($value, ENT_COMPAT, 'UTF-8');
                if ((strpos($value, 'http://') === 0) || (strpos($value, 'https://') === 0)) {
                    $html .= "<a href=\"" . $value . "\">" . $value . "</a>";
                } else {
                    $html .= $value;
                }
            }
            $html .= "</li>\n";
        }
        $html .= "</ul>\n";

        return $html;
    }