public function getBaseUrl()
{
if ($this->_baseUrl === null) {
$appPath = dirname($this->getRequest()->getApplicationFilePath());
$basePath = $this->getBasePath();
if (strpos($basePath, $appPath) === false) {
throw new TConfigurationException('thememanager_baseurl_required');
}
$appUrl = rtrim(dirname($this->getRequest()->getApplicationUrl()), '/\\');
$this->_baseUrl = $appUrl . strtr(substr($basePath, strlen($appPath)), '\\', '/');
}
return $this->_baseUrl;
}