protected function renderTitle()
	{
		// Get default value for site name
		$sitename = $this->getConfig('title.sitename');

		// Value for title, site name if not defined
		$title = ($this->title) ? $this->title : $sitename;
		
		// Get default separator value
		$separator = $this->getConfig('title.separator');

		// Should title show site name
		$show = $this->getConfig('title.show_sitename');

		// Get title position
		$first = $this->getConfig('title.first');

		// Show site name in title
		if ($show)
		{
			// Site name and title values are the same
			if ($sitename == $title)
			{
				return $sitename;
			}
			
			// No site name is defined
			elseif (!$sitename)
			{
				return $title;
			}
			
			// No title is defined
			elseif (!$title)
			{
				return $sitename;
			}
		
			// Get complete title
			else
			{
				return ($first) ? $title.$separator.$sitename : $sitename.$separator.$title;
			}
		}

		// Don't show site name in title
		else
		{
			return $title;
		}
	}