;This parsing routine...
breakdown-content: func [
"breakdown an e-mail content field into its parts"
msg [object!] "e-mail message"
][
article-info: msg/content
end-of-paragraph: rejoin [{.} newline]
content-parts: copy []
foreach part parse/all article-info end-of-paragraph [ append
content-parts part ]
]
;when parsing the following...
First paragraph here.
Then a second paragraph. Another sentence.
A final paragraph.
;creates an undesirable result, as follows...
make object! [
headline: "first headline"
subheadline: "second headline"
body: ["First paragraph here" "" "" "Then a second paragraph" "
Another sentence" "" "" "A final paragraph" ""]
]
;For the "body" value, I would like the block to contain only
individual paragraphs. Parsing by the following value (also above)...
end-of-paragraph: rejoin [{.} newline]
;does not work as I desire (i.e. parsing ONLY by instances of a period
followed by a newline character.) Using a charset value would not work,
because then it would parse for EVERY instance of a period and a
newline, correct? How can I accomplish what I am setting out to do?
(parsing by each instance of a period followed by a newline character.)
Thanks.
-Ryan