-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Oops,
that is it. How embarrassing! Gee, I should take more breaks to relax
the eyes.
Thanks a lot Jason!
K<o>
Jason Johnston wrote:
> Kaj Kandler wrote:
>> -----BEGIN PGP SIGNED MESSAGE-----
>> Hash: SHA1
>>
>> Hi there,
>> I'm stuck and look for the magic touch of a master here.
>>
>> I try to access a component in flow-script like
>> - ---
>> var mailSender =
>> cocoon.getComponent("org.apache.cocoon.mail.MailSender");
>> // mailSender.initialize();
>> try {
>> mailSender.setFrom(form.getChild("email").getValue());
>> mailSender.setTo(recepientAddress);
>> mailSender.setSubject("Plan-B4OOo: question from
>> "+form.getChild("name").getValue());
>> mailSender.setBody(form.getChild("question").getValue());
>> mailSender.send();
>> } finally {
>> cocoon.releaseComponent(mailSender);
>> }
>> - ---
>> I would expect the component to be configured with the values defined in
>> cocoon.xconf
>> - ---
>> <component class="org.apache.cocoon.mail.MailMessageSender"
>> logger="core.mail.MailSender" role="org.apache.cocoon.mail.MailSender">
>> <!--+
>> | SMTP host name, user name, and password.
>> <smtp-host>svn</smtp-host>
>> <smtp-user>myUser</smtp-user>
>> <smtp-password>secretPasswd</smtp-password>
>> +-->
>> </component>
>
> The configuration is commented out... or is that just a copy-paste
> error? :-)
>
> It should work as you describe, as I'm doing the exact same thing
> successfully.
>
> --Jason
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
- --
[EMAIL PROTECTED]
http://conficio.blogspot.com/
================================================
| We teach software one screencast at a time |
================================================
http://www.conficio.com/
Tel: +1 (781) 632 5773 - Fax: +1 (781) 207 9159
Conficio
P.O.Box 761062, Melrose,
MA 02176
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.5 (MingW32)
iD8DBQFEoS97RDUvrJRNjTARAiMeAJ9I3B0BYgP0EGOjxVN/1HNs44X8lwCfSZla
kCHtz7/iuVl6oApmSiJYIKE=
=B90/
-----END PGP SIGNATURE-----
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]