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
|
<?xml version="1.0" encoding="UTF-8"?>
<!-- Reviewed: no -->
<sect2 id="zend.application.available-resources.mail">
<title>Zend_Application_Resource_Mail</title>
<para>
<classname>Zend_Application_Resource_Mail</classname> can be used
to instantiate a transport for <classname>Zend_Mail</classname> or set
the default name and address, as well as the default replyto- name and address.
</para>
<para>
When instantiating a transport, it's registered automatically to
<classname>Zend_Mail</classname>. Though, by setting the
<property>transport.register</property> directive to <constant>FALSE</constant>, this
behaviour does no more occur.
</para>
<example id="zend.application.available-resources.mail.configExample">
<title>Sample Mail Resource Configuration</title>
<para>
Below is a sample <acronym>INI</acronym> snippet showing how to
configure the mail resource plugin.
</para>
<programlisting language="ini"><![CDATA[
resources.mail.transport.type = smtp
resources.mail.transport.host = "smtp.example.com"
resources.mail.transport.auth = login
resources.mail.transport.username = myUsername
resources.mail.transport.password = myPassword
resources.mail.transport.register = true ; True by default
resources.mail.defaultFrom.email = john@example.com
resources.mail.defaultFrom.name = "John Doe"
resources.mail.defaultReplyTo.email = Jane@example.com
resources.mail.defaultReplyTo.name = "Jane Doe"
]]></programlisting>
</example>
</sect2>
|