Hi Jeremie,
On 13 Jun 2014 at 17:33:38, Jeremie BOUSQUET
([email protected](mailto:[email protected])) wrote:
> 2014-06-13 17:30 GMT+02:00 Jeremie BOUSQUET :
>
> > Hi Vincent,
> >
> > Just a small question about the script service, is the following:
> >
> > "$message.addPart("text/plain", "text message")
> > $message.addPart("text/html", "html message")"
> >
>
> To be clearer, does it create a "multipart/alternative" in this case ?
I’ve updated the doc, please check
http://extensions.xwiki.org/xwiki/bin/view/Extension/Mail+Sender+API#HHowtocreateaMultipartalternativewithbothHTMLandtext3F
> > ... the same as doing :
> >
> > "$message.addPart("text/html", "html message", {"alternate" : "text
> > message"})"
> >
> > ?
Nope it’s not the same, see the link.
> > About this:
> >
> > "// Add simple text to message with a ***JavaMail*** header
> > $message.addPart("text", "text message", {"headers" : {
> > "Content-Transfer-Encoding" : "quoted-printable"}})"
> >
> > Technically, it's not a javamail header, it's a mail header.
Fixed, thanks.
> > For the java api sample, the last lines:
> >
> > "send.send(message, session, listener);
> >
> > // Optional: Block till there are no more messages on the sending queue.
> > // Parameter passed is the max time to wait in milliseconds.
> > send.waitTillSent(10000L);"
> >
> > ... should be "sender" not "send" I suppose.
Fixed, thanks
Generally, do you like the API?
There are lots of future ideas to implement several MimeBodyPartFactory!
For example the following:
$message.addPart(“xwiki/docref”, DocumentReference)
Would automatically generate a mime body part with the content of the
referenced document in both text and HTML with all its attachments added,
including embedded images, nice, isn’t it? :)
Thanks
-Vincent
> >
> > Thanks,
> > Jeremie
> >
> >
> >
> > 2014-06-13 16:57 GMT+02:00 [email protected] :
> >
> > Hi devs,
> >>
> >> First version committed in 6.1M2 (thanks Thomas for the move from contrib
> >> to platform).
> >>
> >> See http://extensions.xwiki.org/xwiki/bin/view/Extension/Mail+Sender+API
> >>
> >> Please try it/provide feedback to improve the API!
> >>
> >> Thanks
> >> -Vincent
> >>
> >>
> >> On 12 Jun 2014 at 17:05:21, [email protected] ([email protected]
> >> (mailto:[email protected])) wrote:
> >>
> >> > Hi devs,
> >> >
> >> > Following this email thread
> >> http://markmail.org/message/batmj7h2oibckroy I’ve now progressed with
> >> Lyes and we would like to move our code to XWiki Platform.
> >> >
> >> > More detail is available at
> >> http://design.xwiki.org/xwiki/bin/view/Proposal/MailModule
> >> >
> >> > Here’s my +1
> >> >
> >> > Note that it’s not fully finished but I’d like to start making it
> >> official in 6.1M2 and tune it from there. It’s already working and tested
> >> with some integration test for some use cases.
> >> >
> >> > Thanks
> >> > -Vincent
> >> >
_______________________________________________
devs mailing list
[email protected]
http://lists.xwiki.org/mailman/listinfo/devs