function getTitle()
{
if (!isset($this->_title) && isset($this->name)) {
- $title = $this->name;
- if (substr($title, 0, 6) == 'INBOX/') {
- $title = substr($title, 6);
- }
- $title = str_replace('/', ':', $title);
- $this->_title = Horde_String::convertCharset($title, 'UTF7-IMAP');
+ $this->_title = $this->_namespace->getTitle($this->name);
}
return $this->_title;
}
*/
class Horde_Kolab_Storage_Namespace
{
+
+ /**
+ * Return the title of a folder.
+ *
+ * @param string $name The name of the folder.
+ */
+ public function getTitle($name)
+ {
+ if (substr($name, 0, 6) == 'INBOX/') {
+ $name = substr($name, 6);
+ }
+ $name = str_replace('/', ':', $name);
+ return Horde_String::convertCharset($name, 'UTF7-IMAP');
+ }
}
\ No newline at end of file