blob: e185bae5ebc7e1cb46d3eff1b194a45920b24fa4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
|
<?php
class IMAPServerInformation
{
protected $imap = null;
public function __construct()
{
$this->imap = IMAPManager::getAdminConnection();
}
public function getGreeting()
{
return substr($this->imap->getGreeting(), 5);
}
public function getServerName()
{
return $this->imap->getServerName();
}
public function getServerVersion()
{
return $this->imap->getServerVersion();
}
public function hasCapability($name)
{
return $this->imap->hasCapability($name);
}
public function getCapabilties()
{
if(!($c = $this->imap->capability()))
$c = array();
return $c;
}
public function getHierarchyDelimiter()
{
return $this->imap->getHierarchyDelimiter();
}
public function getAvailableACL()
{
if(!$this->imap->hasCapability('ACL'))
return false;
return $this->imap->getAvailableACL();
}
public function getHost()
{
return substr($this->imap->getURI(), 0, strpos($this->imap->getURI(), ":"));
}
public function getPort()
{
return substr($this->imap->getURI(), strpos($this->imap->getURI(), ":")+1);
}
}
?>
|