zbateson/mailbox-folder

列出并显示存储在本地文件夹中的电子邮件消息

1.1 2021-08-23 16:46 UTC

This package is auto-updated.

Last update: 2024-09-19 21:44:36 UTC


README

显示存储在文件夹中的以MIME消息格式存储的电子邮件邮箱。

Screenshot 1

Screenshot 2

要求

需要PHP 5.4或更高版本。

配置

将config/Prod.default.php复制到config/Prod.php,并根据需要编辑以下值。

// change it if mailbox-folder sits under a different path,
// for example: '/mail'
$di->values['basepath'] = '/';
// update this if you want a different name to show up in the
// title bar
$di->values['appname'] = 'mailbox-folder';
// configure the folder to read email messages from
$di->values['maildir'] = '/path/to/mailbox/folder';

默认情况下,mailbox-folder使用jamesmoss/flywheel创建一个简单的json数据库,并将其存储在sys_get_temp_dir()下的'mailbox-folder'文件夹中。这可以通过在config/Prod.php中添加以下内容来更改,以及其他提到的配置设置

$di->values['writedir'] = '/path/to/writable/dir';

配置基本路径

如果更改基本路径,可能需要修改.htaccess文件中的少量内容

<IfModule mod_rewrite.c>
    # turn on rewriting
    RewriteEngine On

    # turn empty requests into requests for "index.php",
    # keeping the query string intact
    RewriteRule ^$ /index.php [QSA]

    # look for cached versions of files in ./web/cache/
    RewriteCond %{DOCUMENT_ROOT}/cache%{REQUEST_URI} -f
    RewriteRule ^(.*)$ cache/$1 [L]

    # for all files not found in the file system,
    # reroute to "index.php" bootstrap script,
    # keeping the query string intact.
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !favicon.ico$

    # Replace "BASEPATH_HERE" with your basepath as set
    # above in your config
    RewriteRule ^(.*)$ /BASEPATH_HERE/index.php [QSA,L]
</IfModule>

许可

BSD许可 - 请参阅许可协议