Skip to content

Commit d7309b2

Browse files
committed
Config updated
1 parent 8ca4854 commit d7309b2

File tree

1 file changed

+26
-6
lines changed

1 file changed

+26
-6
lines changed

src/config/imap.php

Lines changed: 26 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -136,9 +136,6 @@
136136
| error: "Kerberos error: No credentials cache
137137
| file found (try running kinit) (...)"
138138
| or ['GSSAPI','PLAIN'] if you are using outlook mail
139-
| -Decoder options (currently only the message subject and attachment name decoder can be set)
140-
| 'utf-8' - Uses imap_utf8($string) to decode a string
141-
| 'mimeheader' - Uses mb_decode_mimeheader($string) to decode a string
142139
|
143140
*/
144141
'options' => [
@@ -163,12 +160,35 @@
163160
"sent" => "INBOX/Sent",
164161
"trash" => "INBOX/Trash",
165162
],
166-
'decoder' => [
163+
'open' => [
164+
// 'DISABLE_AUTHENTICATOR' => 'GSSAPI'
165+
]
166+
],
167+
168+
/**
169+
* |--------------------------------------------------------------------------
170+
* | Available decoding options
171+
* |--------------------------------------------------------------------------
172+
* |
173+
* | Available php imap config parameters are listed below
174+
* | -options: Decoder options (currently only the message subject and attachment name decoder can be set)
175+
* | 'utf-8' - Uses imap_utf8($string) to decode a string
176+
* | 'mimeheader' - Uses mb_decode_mimeheader($string) to decode a string
177+
* | -decoder: Decoder to be used. Can be replaced by custom decoders if needed.
178+
* | 'header' - HeaderDecoder
179+
* | 'message' - MessageDecoder
180+
* | 'attachment' - AttachmentDecoder
181+
*/
182+
'decoding' => [
183+
'options' => [
184+
'header' => 'utf-8', // mimeheader
167185
'message' => 'utf-8', // mimeheader
168186
'attachment' => 'utf-8' // mimeheader
169187
],
170-
'open' => [
171-
// 'DISABLE_AUTHENTICATOR' => 'GSSAPI'
188+
'decoder' => [
189+
'header' => \Webklex\PHPIMAP\Decoder\HeaderDecoder::class,
190+
'message' => \Webklex\PHPIMAP\Decoder\MessageDecoder::class,
191+
'attachment' => \Webklex\PHPIMAP\Decoder\AttachmentDecoder::class
172192
]
173193
],
174194

0 commit comments

Comments
 (0)