linux下架设邮箱 MUA篇[RoundCubeWebmail]

合集下载
  1. 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
  2. 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
  3. 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。

RoundCube Web Mail是一个基于浏览器,支持多国语言的IMAP客户端,操作界面看起像一个桌面应用程序。

它提供一个e-mail客户端应该具备的所有功能包括MIME支持,地址薄,文件夹操作,信息搜索和拼写检查。

RoundCube Webmail采用PHP+Ajax开发并且需要MySQL 数据库来存储数据。

用户界面采用XHTML+CSS2设计。

B、安装
B.0、运行环境准备
RoundCube Web Mail只能运行在php环境中,必须先安装好apache+php。

和数据库mysql 或postgresql。

B.1、下载
下载地址:/download
下载文件:roundcubemail-0.5.3.tar.gz
B.2、安装
1.复制到apache运行目录下
cp roundcubemail-0.5.3.tar.gz /var/www/html/
2.解压
tar zxvf roundcubemail-0.5.3.tar.gz
mv roundcubemail-0.5.3 mail
3.修改权限
chown -R root:apache /var/www/html/mail/
cd /var/www/html/mail/
chmod g+w temp/
chmod g+w logs/
4.配置
打开网址:http://192.168.1.254/mail/installer/
按照要求建立配置,后续也可以修改,再初始化数据库。

C、常用配置
配置文件/var/www/html/mail/config/main.inc.php
1.$rcmail_config['default_host'] = '192.168.1.253';
设置默认邮箱的IP(IMAP服务器的IP)。

2.$rcmail_config['smtp_server'] = '192.168.1.253';
设置SMTP服务器的IP。

3.$rcmail_config['product_name'] = 'Web Mail';
设置本项目名称
4.$rcmail_config['language'] = ‘zh_CN’;
设置默认语言。

5.邮箱指定
$rcmail_config['drafts_mbox'] = 'mail/saved-drafts';
草稿箱
$rcmail_config['junk_mbox'] = 'mail/spam-mail';
垃圾邮件
$rcmail_config['sent_mbox'] = 'mail/sent-mail';
$rcmail_config['trash_mbox'] = 'mail/mail-trash';
回收站
6.邮箱夹
邮件夹的设定文件在:home目录下.mailboxlist
文件中的内容和顺序决定邮件夹的内容和顺序
7.$rcmail_config['default_charset'] = 'UTF-8';
默认字符集
8.$rcmail_config['timezone'] = 8;
默认时区为东8区
9.$rcmail_config['prettydate'] = false;
时间显示格式true为短格式,false为长格式。

10.几种时间格式
$rcmail_config['date_short'] = 'D H:i';
短格式时时间显示方式
$rcmail_config['date_long'] = 'd.m.Y H:i';
长格式时时间显示方式
$rcmail_config['date_today'] = 'H:i';
今天时间显示方式
11.$rcmail_config['preview_pane'] = true;
显示预览窗口
D、组件配置
组件目录在plugins,这个版本共有22个组件,要安装那个组件就在$rcmail_config['plugins'] = array();加入组件的文件夹名。

$rcmail_config*'plugins'+ = array(‘help’);
D.0、组件来源
官网组件:/wiki/Plugin_Repository
D.1、首次登陆对话框(new_user_dialog)
$rcmail_config['plugins'] = array(‘new_user_dialog’);
1.复制new_user_dialog/ localization/目录下zh_TW.inc
cp zh_TW.inc zh_CN.inc
不知道为什么没有zh_CN的语言包,还好有繁体的根据它修改一下。

D.2、标记垃圾邮件(markasjunk)
$rcmail_config['plugins'] = array(‘markasjunk’);
1.配置zh_CN的语言包
D.3、标记垃圾邮件(markasjunk2)
在原有功能上的扩展,在垃圾邮件箱子时,有恢复按钮
1.下载
wget /roundcube/plugins/markasjunk2.tar.gz
D.4、存档箱(archive)
在邮件工具栏上添加一个新按钮,它可以移动你的邮箱到用户自定义存档箱内。

D.5、上传附件到数据库中(database_attachments)
$rcmail_config['plugins'] = array(‘database_attachments’);
不需要做什么配置,生效后,上传的附件将保存到数据库cache表中。

D.6、用户信息(userinfo)
$rcmail_config['plugins'] = array(‘userinfo’);
1.配置zh_CN的语言包
D.7、全局通讯录(globaladdressbook)
$rcmail_config['plugins'] = array(‘globaladdressbook’);
1.下载
wget /roundcube/plugins/globaladdressbook.tar.gz
2.解压globaladdressbook.tar.gz到roundcube的插件目录
tar zxvf globaladdressbook.tar.gz -C /var/www/html/mail/plugins/
3.配置插件
cd /var/www/ html/mail/plugins/globaladdressbook
cp config.inc.php.dist config.inc.php
4.设置配置文件
vi config.inc.php
$rcmail_config['globaladdressbook_readonly'] = true;
设置为只读
$rcmail_config['globaladdressbook_groups'] = true;
设置全局地址本可以添加组
$rcmail_config['globaladdressbook_admin'] = 'jizhou';
指定全局地址本的管理员
$rcmail_config['globaladdressbook_autocomplete'] = true;
设置写收件人地址时,可在下拉菜单中显示全局地址本中的邮箱地址
D.8、右键菜单(contextmenu)
$rcmail_config['plugins'] = array(‘contextmenu’);
1.下载
wget /roundcube/plugins/contextmenu.tar.gz
2.将这个插件解压到roundcube的插件目录
tar zxvf contextmenu.tar.gz -C /var/www/html/mail/plugins/
3. 配置插件
该插件不需要做什么配置
D.9、复制邮件(copymessage)
在右键菜单中增加复制邮件功能菜单。

配置语言包即可,无特别设置。

1.下载
wget /roundcube/plugins/copymessage.tar.gz
D.10、修改密码(password)
$rcmail_config['plugins'] = array(‘password’);
1.配置zh_CN的语言包
2.配置插件
cp config.inc.php.dist config.inc.php
3.配置config.inc.php
$rcmail_config['password_driver'] = 'chpasswd';
因为我使用的是sendmail,使用用linux用户。

Roundcube运行在apache httpd下,而httpd 运行用户是apache。

现在要php能够修改linux用户。

需要在linux下安装chpasswd和sudo。

chpasswd实现单条命令修改linux用户密码,而修改密码的权限只有root有,所用需要sudo
给运行php的apache用户增加chpasswd的权限。

4.配置sudo
应有命令visudo修改文件/etc/sudoers
在文件末尾添加:apache ALL=NOPASSWD:/usr/sbin/chpasswd
此行代码是给apache用户增加chpasswd的权限。

并注释掉Defaults requiretty这行,否则会出现sudo:sorry,you must have a tty to run sudo的错误。

D.11、SpamAssassin的用户首选项(SQL)(sauserprefs)
$rcmail_config['plugins'] = array(‘sauserprefs’);
1.下载
wget /roundcube/plugins/sauserprefs.tar.gz
2.准备
SpamAssassin需要安装
3.设置配置文件
$rcmail_config['sauserprefs_db_dsnw'] =’’;
spamassassin数据库连接
$rcmail_config['sauserprefs_sql_table_name'] = "userpref";
保存用户首选项的表,在数据库中创建表userpref
$rcmail_config['sauserprefs_sql_username_field'] = "username";
$rcmail_config['sauserprefs_sql_preference_field'] = "preference";
$rcmail_config['sauserprefs_sql_value_field'] = "value";
创建的表userpref必须包含username用户名,preference选项,value值,三个字段CREATE TABLE userpref
(
id int4 NOT NULL DEFAULT nextval('userpref_id_seq'::regclass),
username varchar(128),
preference varchar(64),
value text,
CONSTRAINT userpref_pkey PRIMARY KEY (id)
)
$rcmail_config['sauserprefs_whitelist_sync'] = FALSE;
启用的白名单同步,用户添加通讯录时,自动添加到白名单中。

删除时自动删除。

$rcmail_config['sauserprefs_dont_override'] = array();
不要让这些设置由用户重写
$rcmail_config['sauserprefs_default_prefs'] = array();
默认设置
D.12、发件时通讯录选择(compose_addressbook)
添加一个可以在发件时选择过滤通讯录的按钮。

该插件需要jqueryui(jquery-ui for roundcube) 插件支持,故要同时安装该插件。

1.下载
下载地址:/p/roundcube-plugins/
2.将这个插件解压到roundcube的插件目录
tar jqueryui-1.8.6.1.tgz -C /var/www/html/mail/plugins/
tar compose_addressbook-4.2.tgz -C /var/www/html/mail/plugins/
3. 配置插件
该插件不需要做什么配置
D.13、又一种帮助(help_ui)
安装后在邮箱界面下面出现一个帮助按钮,点击可使用。

该插件需要jqueryui(jquery-ui for roundcube) 插件支持,故要同时安装该插件。

1.下载
下载地址:/p/roundcube-plugins/
2.将这个插件解压到roundcube的插件目录
tar zxvf help_ui-0.92.tgz
3.配置插件
cp config.inc.php.dist config.inc.php
D.14、快捷键(keyboard_shortcuts)
安装后在邮箱界面下面出现一个键盘的按钮,点击可查看快捷键使用方法。

该插件需要jqueryui(jquery-ui for roundcube) 插件支持,故要同时安装该插件。

1.下载
下载地址:/p/roundcube-plugins/
2.将这个插件解压到roundcube的插件目录
tar zxvf keyboard_shortcuts-1.7.tgz keyboard shortcuts (requires jqueryui)
3. 配置插件
该插件不需要做什么配置
D.15、邮件高亮显示(message_highlight)
安装后可以设置满足规则的邮件高亮显示,达到警示的功能。

该插件需要jqueryui(jquery-ui for roundcube) 插件支持,故要同时安装该插件。

1.下载
下载地址:/p/roundcube-plugins/
2.将这个插件解压到roundcube的插件目录
tar zxvf message_highlight-1.0.6.tgz
E、调整界面
E.1、自定义图片
1.Logo图片
skins/default/images/roundcube_logo.png
2.水印图片
skins/default/images/watermark.gif
E.2、修正zh_CN语言包
这个版本的中文支持不太好,参考zh_TW。

cd /var/www/html/mail/program/localization/zh_CN
vi labels.inc
添加以下内容
$labels['reqmdn'] = '永远索取读取回条';
$labels['reqdsn'] = '总是要求传送状态通知';
$labels['replysamefolder'] = '将回复和回复信件放置在相同邮件夹';
$labels['contacts'] = '联系人';
$labels['contactproperties'] = '联系人信息';
$labels['autosendknown'] = '只对我的联系人传送回条,其他询问用户';
$labels['autosendknownignore'] = '只对我的联系人传送回条,其他忽略';
$labels['properties'] = '属性';
$labels['folderproperties'] = '邮件夹属性';
$labels['parentfolder'] = '上一层邮件夹';
$labels['location'] = '位置';
$labels['info'] = '信息';
$labels['getfoldersize'] = '点击显示邮件夹大小';
$labels['editidents'] = '编辑发件人身份';
$labels['addfollowupto'] = '添加信件更随';
$labels['followupto'] = '信件更随至';
$labels['dsn'] = '传送状态通知';
F、通过设置php配置邮箱
F.1、设置邮件、附件大小——max
vi /etc/php.ini
upload_max_filesize =50M
上传文件的最大值
post_max_size =70M
表单提交的最大值
max_execution_time=300
max_input_time=600
memory_limit = 600M
一个脚本所能够申请到的最大内存字节数,一般设置为内存的四分之一
G、完整配置文件批注
G.1、日志、调试(LOGGING/DEBUGGING)
$rcmail_config['debug_level'] = 1;
system error reporting: 1 = log; 2 = report (not implemented yet), 4 = show, 8 = trace
系统错误日志,1:记录在日志文件中,2:功能未实现,4:在网页中显示,8:追踪$rcmail_config['log_driver'] = 'file';
log driver: 'syslog' or 'file'.
错误日志存放位置,'file':存放在/logs/error,'syslog':存放系统日志中
$rcmail_config['log_date_format'] = 'Y-M-d H:i:s O';
date format for log entries
日志文件中的时间格式
$rcmail_config['syslog_facility'] = LOG_USER;
Syslog facility to use, if using the 'syslog' log driver.
若使用'syslog'系统日志,则使用的日志工具
$rcmail_config['smtp_log'] = true;
Log sent messages to <log_dir>/sendmail or to syslog
True:把smtp日志记录在/logs/sendmail文件中,False:不记录
$rcmail_config['log_logins'] = true;
Log successful logins to <log_dir>/userlogins or to syslog
True:把用户成功登录日志记录在/logs/sendmail文件中,False:不记录
$rcmail_config['sql_debug'] = false;
Log SQL queries to <log_dir>/sql or to syslog
True:把SQL错误日志记录在/logs/sql文件中,False:不记录
$rcmail_config['imap_debug'] = false;
Log IMAP conversation to <log_dir>/imap or to syslog
True:把imap调试日志记录在/logs/imap文件中,False:不记录
$rcmail_config['ldap_debug'] = false;
Log LDAP conversation to <log_dir>/ldap or to syslog
True:把imap调试日志记录在/logs/imap文件中,False:不记录
$rcmail_config['smtp_debug'] = false;
Log SMTP conversation to <log_dir>/smtp or to syslog
True:把smtp调试日志记录在/logs/ smtp文件中,False:不记录
G.2、交互式邮件存取协议(IMAP)
$rcmail_config['default_host'] = '192.168.1.253';
the mail host chosen to perform the log-in.leave blank to show a textbox at login, give a list of hosts to display a pulldown menu or set one host as string.To use SSL/TLS connection, enter hostname with prefix ssl:// or tls://.Supported replacement variables:%n - http hostname ($_SERVER['SERVER_NAME']) %d - domain (http hostname without the first part) For example %n = mail.domain.tld, %d = domain.tld
邮件登录主机。

’’:在登录是显示一个输入框,字符串数组array(‘x’,’xx’):显示一个下拉菜单,字符串’xx’:则为默认邮箱登录时不显示,SSL/TLS连接:主机名以ssl://或tls://开头,支持变量替换:%n主机名称($_SERVER['SERVER_NAME']),%d域名,若主机名为mail.domain.tld,%n = mail.domain.tld,,%d = domain.tld。

$rcmail_config['default_port'] = 143;
TCP port used for IMAP connections
Imap端口
$rcmail_config['imap_auth_type'] = null;
IMAP AUTH type (DIGEST-MD5, CRAM-MD5, LOGIN, PLAIN or empty to use best server supported one)
IMAP AUTH类型,选择服务支持最好的一个
$rcmail_config['imap_delimiter'] = null;
If you know your imap's folder delimiter, you can specify it here.Otherwise it will be determined automatically
如果你知道你的IMAP的文件夹分隔符,你可以在此指定它,否则就让它会自动确定。

$rcmail_config['imap_ns_personal'] = null;
$rcmail_config['imap_ns_other'] = null;
$rcmail_config['imap_ns_shared'] = null;
If IMAP server doesn't support NAMESPACE extension, but you're using shared folders or personal root folder is non-empty, you'll need to set these options. All can be strings or arrays of strings. Folders need to be ended with directory separator, e.g. "INBOX." (special directory "~" is an exception to this rule) These can be used also to overwrite server's namespaces.
如果IMAP服务器不支持命名空间扩展,但你使用共享文件夹或个人的根文件夹是非空,
你需要设置这些选项。

这些选项的值可以是字符串或字符串数值。

文件夹需要以目录分隔符结尾,如“INBOX.”。

(特殊的目录"~"是对这一规则的例外),这些也可用于覆盖服务器的命名空间。

$rcmail_config['imap_force_caps'] = false;
By default IMAP capabilities are readed after connection to IMAP server In some cases, e.g.
when using IMAP proxy, there's a need to refresh the list after login. Set to True if you've got this case.
在某些情况下连接后服务器后IMAP默认被读取,例如当使用IMAP代理,登录后需要刷新列表。

若你有这种情况的话就设置为True。

$rcmail_config['imap_force_lsub'] = false;
By default list of subscribed folders is determined using LIST-EXTENDED extension if available. Some servers (dovecot 1.x) returns wrong results for shared namespaces in this case. /ticket/1486225 Enable this option to force LSUB command usage instead.
若可用订阅文件夹的默认列表确认被用作名单扩展。

在这种情况下一些服务器(dovecot
1. x)返回错误的结果为共同命名空间。

$rcmail_config['imap_timeout'] = 0;
IMAP connection timeout, in seconds. Default: 0 (no limit)
IMAP连接超时时间,秒,默认:0(不限制)。

$rcmail_config['imap_auth_cid'] = null;
Optional IMAP authentication identifier to be used as authorization proxy
可选的IMAP认证标识符作为授权代理
$rcmail_config['imap_auth_pw'] = null;
Optional IMAP authentication password to be used for imap_auth_cid
可选的IMAP认证密码用来作imap_auth_cid
G.3、简单邮件传输协议(SMTP)
$rcmail_config['smtp_server'] = '192.168.1.253';
SMTP server host (for sending mails). To use SSL/TLS connection, enter hostname with prefix ssl:// or tls://,If left blank, the PHP mail() function is used,Supported replacement variables:%h - user's IMAP hostname,%n - http hostname ($_SERVER['SERVER_NAME']),%d - domain (http hostname without the first part),%z - IMAP domain (IMAP hostname without the first part).For example %n = mail.domain.tld, %d = domain.tld
SMTP服务主机(发送邮件)。

SSL/TLS连接:主机名以ssl://或tls://开头,空白:使用php的main()函数,支持变量替换:%h 用户IMAP主机,%n http主机($_SERVER['SERVER_NAME']),%d域名(没有第一部分的主机名),%z IMAP域名(没有第一部分的IMAP主机名)。

若主机名为mail.domain.tld,%n = mail.domain.tld,,%d = domain.tld。

$rcmail_config['smtp_port'] = 25;
SMTP port (default is 25; 465 for SSL)
SMTP端口(默认25;SSL465)
$rcmail_config['smtp_user'] = '';
SMTP username (if required) if you use %u as the username Roundcube will use the current username for login
SMTP用户名(如果需要)如果你使用%u作为用户名,Roundcube将使用当前登录用户。

$rcmail_config['smtp_pass'] = '';
SMTP password (if required) if you use %p as the password Roundcube will use the current user's password for login
SMTP密码(如果需要)如果你使用%p作为密码,Roundcube将使用当前登录用户的密码。

$rcmail_config['smtp_auth_type'] = '';
SMTP AUTH 类型,选择服务支持最好的一个。

$rcmail_config['smtp_auth_cid'] = null;
Optional SMTP authentication identifier to be used as authorization proxy
可选的SMTP认证标识符作为授权代理
$rcmail_config['smtp_auth_pw'] = null;
Optional SMTP authentication password to be used for smtp_auth_cid
可选的SMTP认证密码用来smtp_auth_cid
$rcmail_config['smtp_helo_host'] = '';
SMTP HELO host.Hostname to give to the remote server for SMTP 'HELO' or 'EHLO' messages.
Leave this blank and you will get the server variable 'server_name' or localhost if that isn't defined.
SMTP HELO主机。

主机名给远程服务器SMTP 'HELO' 或'EHLO'消息。

空白:你将得到'server_name'服务变量的值,若未定义则得到localhost。

$rcmail_config['smtp_timeout'] = 0;
SMTP connection timeout, in seconds. Default: 0 (no limit)
SMTP连接超时时间,秒,默认:0(不限制)。

G.4、系统(SYSTEM)
$rcmail_config['enable_installer'] = false;
THIS OPTION WILL ALLOW THE INSTALLER TO RUN AND CAN EXPOSE SENSITIVE CONFIG DATA. ONLY ENABLE IT IF YOU'RE REALLY SURE WHAT YOU'RE DOING!
此选项会允许安装程序运行和能揭露敏感的配置数据。

只有使它如果你真的确定你在干嘛!
$rcmail_config['log_dir'] = 'logs/';
use this folder to store log files (must be writeable for apache user).This is used by the 'file' log driver.
使用该文件夹存储日志文件(apache用户必须有写的权限)。

log driver 设置为'file'方才有效。

$rcmail_config['temp_dir'] = 'temp/';
use this folder to store temp files (must be writeable for apache user)
使用该文件夹存储临时文件(apache用户必须有写的权限)。

$rcmail_config['enable_caching'] = false;
enable caching of messages and mailbox data in the local database.this is recommended if the IMAP server does not run on the same machine.
使缓存信息和邮箱数据存放在数据库中。

如果IMAP服务器不运行在同一台机器上推荐使用。

信息存放在数据库messages表和cache表。

$rcmail_config['message_cache_lifetime'] = '10d';
lifetime of message cache. possible units: s, m, h, d, w
消息缓存生命周期,单位:s、m、h、d、w。

$rcmail_config['force_https'] = false;
enforce connections over https.with this option enabled, all non-secure connections will be redirected.set the port for the ssl connection as value of this option if it differs from the default 443.
执行https连接。

使用此选项启用时,所有非安全连接将被重定向。

若它不同于默认端口443,设置ssl连接端口。

$rcmail_config['use_https'] = false;
tell PHP that it should work as under secure connection.even if it doesn't recognize it as secure ($_SERVER['HTTPS'] is not set). e.g. when you're running Roundcube behind a https proxy.
告诉PHP它应该工作在安全连接下。

即使它并不认为它是安全的($_SERVER['HTTPS']没有设置)。

例如当你使Roundcube 运行在https代理后面。

$rcmail_config['login_autocomplete'] = 0;
Allow browser-autocompletion on login form. 0 - disabled, 1 - username and host only, 2 - username, host, password
允许在浏览器自动完成登录表格。

0禁用,1只需用户名和主机名,2需用户名、主机名和密码。

$rcmail_config['login_lc'] = false;
If users authentication is not case sensitive this must be enabled. You can also use it to force conversion of logins to lower case.
如果用户的认证是不区分大小写这必须启用。

您还可以用它来迫使登录转换为小写。

$rcmail_config['auto_create_user'] = true;
automatically create a new Roundcube user when log-in the first time. a new user will be created once the IMAP login succeeds. set to false if only registered users can use this service
第一次登录时,自动创建一个新的Roundcube用户。

一旦IMAP登录成功一个新的用户将被创建。

如果设置为false,只有注册用户可以使用这项服务。

$rcmail_config['skin_include_php'] = false;
Includes should be interpreted as PHP files
包含文件应被解释为php文件。

$rcmail_config['session_lifetime'] = 10;
Session lifetime in minutes. must be greater than 'keep_alive'/60
Session实效时间,分钟,该值必须大于'keep_alive'/60的值。

$rcmail_config['ip_check'] = false;
check client IP in session authorization
检查客户端会话IP。

$rcmail_config['double_auth'] = false;
Use an additional frequently changing cookie to athenticate user sessions. There have been problems reported with this feature.
使用一个额外的经常变化的cookie来检查客户session。

已经有与此功能的问题报告。

$rcmail_config['referer_check'] = false;
check referer of incoming requests
检查传入请求的引用者
$rcmail_config['des_key'] = '35baINv$xxxxHYtHe*479be4';
this key is used to encrypt the users imap password which is stored. in the session record (and the client cookie if remember password is enabled). please provide a string of exactly
24 chars.
这个key用于加密存储的用户imap密码。

在session记录中(若客户端的cookie和记住密码已启用)。

请提供准确24个字符的字符串。

$rcmail_config['username_domain'] = '';
Automatically add this domain to user names for login. Only for IMAP servers that require full e-mail addresses for login. Specify an array with 'host' => 'domain' values to support multiple hosts. Supported replacement variables: %h - user's IMAP hostname, %n - http hostname ($_SERVER['SERVER_NAME']), %d - domain (http hostname without the first part), %z - IMAP domain (IMAP hostname without the first part), For example %n = mail.domain.tld, %d = domain.tld
为登录用户名自动添加这个域名。

仅适用于需要完整的电子邮件地址登录的IMAP服务器。

指定一个含有'host' => 'domain'值的数组来支持多台主机。

支持变量替换:%h 用户IMAP主机,%n http主机($_SERVER['SERVER_NAME']),%d域名(没有第一部分的主机名),%z IMAP域名(没有第一部分的IMAP主机名)。

若主机名为mail.domain.tld,%n = mail.domain.tld,,%d = domain.tld。

$rcmail_config['mail_domain'] = '';
This domain will be used to form e-mail addresses of new users. Specify an array with 'host' => 'domain' values to support multiple hosts. Supported replacement variables: %h - user's IMAP hostname. %n - http hostname ($_SERVER['SERVER_NAME']), %d - domain (http hostname without the first part), %z - IMAP domain (IMAP hostname without the first part),For example %n = mail.domain.tld, %d = domain.tld
该域名将被用于形成新的用户电子邮件地址。

指定一个含有'host' => 'domain'值的数组来支持多台主机。

支持变量替换:%h 用户IMAP主机,%n http主机($_SERVER['SERVER_NAME']),%d域名(没有第一部分的主机名),%z IMAP域名(没有第一部分的IMAP主机名)。

若主机名为mail.domain.tld,%n = mail.domain.tld,,%d = domain.tld。

$rcmail_config['password_charset'] = 'ISO-8859-1';
Password charset. Use it if your authentication backend doesn't support UTF-8. Defaults to ISO-8859-1 for backward compatibility
密码字符集。

如果您的验证后端不支持UTF-8,为了向后兼容,默认为ISO-8859-1。

$rcmail_config['sendmail_delay'] = 0;
How many seconds must pass between emails sent by a user
多少秒之间必须通过由用户发送电子邮件。

$rcmail_config['max_recipients'] = 0;
Maximum number of recipients per message. Default: 0 (no limit)
最大数量的每封邮件的收件人。

默认:0(无限制)。

$rcmail_config['max_group_members'] = 0;
Maximum allowednumber of members of an address group. Default: 0 (no limit).If 'max_recipients' is set this value should be less or equal
一个地址组的成员允许的最大数量。

默认:0(无限制)。

应小于或等于'max_recipients'设置的值。

$rcmail_config['useragent'] = 'Roundcube Webmail/'.RCMAIL_VERSION;
add this user-agent to message headers when sending
当邮件发送时在邮件User-Agent栏目中添加此信息。

$rcmail_config['product_name'] = ' Web Mail';
use this name to compose page titles
使用这个名称来撰写网页标题
$rcmail_config['include_host_config'] = false;
try to load host-specific configuration. see /wiki/Howto_Config for more details
尝试加载特定于主机的配置
$rcmail_config['generic_message_footer'] = '';
path to a text file which will be added to each sent message. paths are relative to the Roundcube root folder
指定一个文本文件的路径,该文件将被添加到每个发送的消息中。

路径是相对于Roundcube根文件夹
$rcmail_config['generic_message_footer_html'] = '';
path to a text file which will be added to each sent HTML message. paths are relative to the Roundcube root folder
指定一个文本文件的路径,该文件将被添加到每个发送的html消息中。

路径是相对于Roundcube根文件夹。

$rcmail_config['http_received_header'] = false;
add a received header to outgoing mails containing the creators IP and hostname
在传出邮件中添加接收头包含的创造者IP和主机名。

$rcmail_config['http_received_header_encrypt'] = false;
Whether or not to encrypt the IP address and the host name. these could, in some circles, be considered as sensitive information; however, for the administrator, these could be invaluable help when tracking down issues.
是否要加密的IP地址和主机名。

这些在某些情况下被视为敏感的信息,然而,对于管理员,在跟踪问题时,这可能是非常宝贵的帮助。

$rcmail_config['mail_header_delimiter'] = NULL;
This string is used as a delimiter for message headers when sending. a message via mail() function. Leave empty for auto-detection
此字符串用来作为分隔邮件标题时发送。

通过mail()函数的消息。

留空为自动检测。

$rcmail_config['line_length'] = 72;
number of chars allowed for line when wrapping text. text wrapping is done when composing/sending messages
线路数目时允许换行的文本字符。

文字环绕完成时撰写/发送邮件
$rcmail_config['send_format_flowed'] = true;
send plaintext messages as format=flowed
纯文本格式发送邮件
$rcmail_config['session_domain'] = '';
session domain:
session域名
$rcmail_config['dont_override'] = array();
don't allow these settings to be overriden by the user
不要让这些设置由用户重写
$rcmail_config['identities_level'] = 0;
Set identities access level:
0 - many identities with possibility to edit all params
1 - many identities with possibility to edit all params but not email address
2 - one identity with possibility to edit all params
3 - one identity with possibility to edit all params but not email address
设置身份访问级别:
0:有多个ID的权限可以修改所有参数
1:有多个ID的权限可以修改除邮件地址的所有参数
2:只有一个ID的权限可以修改所有参数
3:有只有一个ID的权限可以修改修改除邮件地址的所有参数
$rcmail_config['mime_magic'] = '/usr/share/misc/magic';
mime magic database
mime magic数据库
$rcmail_config['email_dns_check'] = false;
Enable DNS checking for e-mail address validation
使DNS检查电子邮件地址的验证
G.5、插件(PLUGINS)
$rcmail_config['plugins'] = array('new_user_dialog','markasjunk' ,'password','userinfo');
List of active plugins (in plugins/ directory)
把plugins/目录下的文件夹名,加到数组中。

G.6、用户界面(USER INTERFACE)
$rcmail_config['message_sort_col'] = '';
default messages sort column. Use empty value for default server's sorting, or 'arrival', 'date', 'subject', 'from', 'to', 'size', 'cc'
默认信息排序。

空值为服务器排序的默认值,你可选择以下值排序。

$rcmail_config['message_sort_order'] = 'DESC';
default messages sort order
升序、降序排序设置
$rcmail_config['list_cols'] = array('subject', 'status', 'from', 'date', 'size', 'flag', 'attachment');
These cols are shown in the message list. Available cols are: subject, from, to, cc, replyto, date, size, status, flag, attachment
在邮件列表中显示的列。

$rcmail_config['language'] = 'zh_CN';
the default locale setting (leave empty for auto-detection)
语言环境设置
$rcmail_config['date_short'] = 'D H:i';
use this format for short date display (date or strftime format)
短时间格式
$rcmail_config['date_long'] = 'Y.m.d H:i';
use this format for detailed date/time formatting (date or strftime format)
长时间格式
$rcmail_config['date_today'] = 'H:i';
use this format for today's date display (date or strftime format)
今天时间格式
$rcmail_config['drafts_mbox'] = 'mail/saved-drafts';
store draft message is this mailbox,leave blank if draft messages should not be stored
草稿箱
$rcmail_config['junk_mbox'] = 'mail/spam-mail';
store spam messages in this mailbox
垃圾邮件箱
$rcmail_config['sent_mbox'] = 'mail/sent-mail';
store sent message is this mailbox, leave blank if sent messages should not be stored
已发送邮件箱
$rcmail_config['trash_mbox'] = 'mail/mail-trash';
move messages to this folder when deleting them, leave blank if they should be deleted directly
回收箱
$rcmail_config['default_imap_folders'] = array('INBOX', 'Drafts', 'Sent', 'Junk', 'Trash');
display these folders separately in the mailbox list. these folders will also be displayed with localized names
在邮筒列表中显示这些文件夹,这些文件夹也将被显示为本地化的名字。

$rcmail_config['create_default_folders'] = false;
automatically create the above listed default folders on login
在登录后自动产生上述默认文件夹
$rcmail_config['protect_default_folders'] = true;
protect the default folders from renames, deletes, and subscription changes
保护默认的文件夹不能重命名,删除和订阅变化
$rcmail_config['quota_zero_as_unlimited'] = false;
if in your system 0 quota means no limit set this option to true
如果在你的系统中0配额意味着没有限定此选项true
$rcmail_config['enable_spellcheck'] = true;
Make use of the built-in spell checker. It is based on GoogieSpell. Since Google only accepts connections over https your PHP installatation. requires to be compiled with Open SSL support
利用内置的拼写检查。

它是基于GoogieSpell。

自从在谷歌仅接受连接你的PHP 安装。

https需要编译时打开SSL的支持。

$rcmail_config['spellcheck_engine'] = 'pspell';
Set the spell checking engine. 'googie' is the default. 'pspell' is also available,but requires the Pspell extensions. When using Nox Spell Server, also set 'googie' here.
把拼写检查引擎。

“googie”是默认值。

“pspell”是可用的,但是需要pspell延伸。

当使用法术服务器,也规定了Nox的googie”在这里。

$rcmail_config['spellcheck_uri'] = '';
For a locally installed Nox Spell Server, please specify the URI to call it. Get Nox Spell Server from /labs/?page_id=72.Leave empty to use the Google spell checking service, what means.that the message content will be sent to Google in order to check spelling
为本地安装Nox Spell服务器,请指定URI调用它。

$rcmail_config['spellcheck_languages'] = NULL;
These languages can be selected for spell checking. Configure as a PHP style hash array: array('en'=>'English', 'de'=>'Deutsch'); Leave empty for default set of available language.
可以选择拼写检查的语言。

$rcmail_config['max_pagesize'] = 200;
don't let users set pagesize to more than this value if set
不要让用户设定pagesize超过此值
$rcmail_config['min_keep_alive'] = 60;
Minimal value of user's 'keep_alive' setting (in seconds), Must be less than 'session_lifetime' 用户可设置的'keep_alive'最小值,不得超过'session_lifetime'
G.7、地址簿(ADDRESSBOOK SETTINGS)
$rcmail_config['address_book_type'] = 'sql';
This indicates which type of address book to use. Possible choises: 'sql' (default) and 'ldap'. If set to 'ldap' then it will look at using the first writable LDAP. address book as the primary address book and it will not display the SQL address book in the 'Address Book' view.
这表明哪一类型的地址簿使用。

'sql' 或'ldap'
$rcmail_config['ldap_public'] = array();
In order to enable public ldap search, configure an array like the Verisign. example further below. if you would like to test, simply uncomment the example.
$rcmail_config['autocomplete_addressbooks'] = array('sql');
An ordered array of the ids of the addressbooks that should be searched, when populating address autocomplete fields server-side. ex: array('sql','Verisign');
$rcmail_config['autocomplete_min_length'] = 1;
The minimum number of characters required to be typed in an autocomplete field, before address books will be searched. Most useful for LDAP directories that may need to do lengthy results building given overly-broad searches
G.8、用户偏好(USER PREFERENCES)
$rcmail_config['default_charset'] = 'UTF-8';
Use this charset as fallback for message decoding
默认字符集
$rcmail_config['skin'] = 'default';
skin name: folder from skins/
皮肤
$rcmail_config['pagesize'] = 40;
show up to X items in list view
一页显示数量
$rcmail_config['timezone'] = 8;
use this timezone to display date/time
时区
$rcmail_config['dst_active'] = (bool)date('I');
is daylight saving On?
夏令时
$rcmail_config['prefer_html'] = true;。

相关文档
最新文档