mirror of
https://bitbucket.org/jsuto/piler.git
synced 2024-11-08 02:41:59 +01:00
Added support for imap-ssl for the gui import
Signed-off-by: Janos SUTO <sj@acts.hu>
This commit is contained in:
parent
828964ec4c
commit
a31f5b7a26
@ -48,11 +48,15 @@ class ControllerImportTest extends Controller {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
else if($this->request->post['type'] == 'imap') {
|
else if($this->request->post['type'] == 'imap' || $this->request->post['type'] == 'imap-ssl') {
|
||||||
|
$ssl = false;
|
||||||
|
if($this->request->post['type'] == 'imap-ssl') {
|
||||||
|
$ssl = 'SSL';
|
||||||
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
|
||||||
$conn = new Zend_Mail_Protocol_Imap($this->request->post['server'], '143', false);
|
$conn = new Zend_Mail_Protocol_Imap($this->request->post['server'], null, $ssl);
|
||||||
|
|
||||||
$login = $conn->login($this->request->post['username'], $this->request->post['password']);
|
$login = $conn->login($this->request->post['username'], $this->request->post['password']);
|
||||||
|
|
||||||
@ -76,5 +80,3 @@ class ControllerImportTest extends Controller {
|
|||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
?>
|
|
||||||
|
@ -31,6 +31,7 @@
|
|||||||
<select name="type" id="type">
|
<select name="type" id="type">
|
||||||
<option value="pop3"<?php if(isset($a['type']) && $a['type'] == 'pop3') { ?> selected="selected"<?php } ?>>pop3</option>
|
<option value="pop3"<?php if(isset($a['type']) && $a['type'] == 'pop3') { ?> selected="selected"<?php } ?>>pop3</option>
|
||||||
<option value="imap"<?php if(isset($a['type']) && $a['type'] == 'imap') { ?> selected="selected"<?php } ?>>imap</option>
|
<option value="imap"<?php if(isset($a['type']) && $a['type'] == 'imap') { ?> selected="selected"<?php } ?>>imap</option>
|
||||||
|
<option value="imap-ssl"<?php if(isset($a['type']) && $a['type'] == 'imap-ssl') { ?> selected="selected"<?php } ?>>imap-ssl</option>
|
||||||
</select>
|
</select>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
Loading…
Reference in New Issue
Block a user