public function expandUrl($url)
    {
        if (! is_object($url)) {
            $url = new SimpleUrl($url);
        }
        $location = $this->getBaseUrl() ? $this->getBaseUrl() : new SimpleUrl();

        return $url->makeAbsolute($location->makeAbsolute($this->getUrl()));
    }