protected function getLink($terms, $format = null)
    {
        if (!$terms) {
            return null;
        }
        $link = 'search/SearchForm?Search='.rawurlencode($terms);
        if ($format) {
            $link .= '&format='.rawurlencode($format);
        }
        return $link;
    }