Anonymous_User Absent Member.
Absent Member.
2077 views

read signature as plain text

Hi,

when reading the (default) signature of a mailbox, the result comes as
HTML text. But I need the signature as plain text only. Is there a way to
read it in plain text directly or to have it converted from html to plain
text?

Thanks in advance,
Frank

Labels (1)
0 Likes
4 Replies
s_vogel Absent Member.
Absent Member.

Re: read signature as plain text

How do you get the HTML anyways? I am only able to get the MIME string and the have to manually Base64 decode the body text to get the HTML at least
0 Likes
Anonymous_User Absent Member.
Absent Member.

Re: read signature as plain text

I've used gwAccount.Signatures.GetDefault.Body, which is a byte-array in
fact.

In my case it looks like a a multi-part MIME message, one of the parts
being of content type "text/html". Within this part I can see the
signature text in HTML format.

I could now try to find some code to transfer HTML to plain text, but on
the other hand Groupwise is doing this for a signature anyway, therefor
it would be straight forward to have Groupwise doing the work.

In article <s_vogel.6syw8n@no-mx.forums.novell.com>, s_vogel@no-
mx.forums.novell.com says...
>
> How do you get the HTML anyways? I am only able to get the MIME string
> and the have to manually Base64 decode the body text to get the HTML at
> least
>
>
> --
> s_vogel
> ------------------------------------------------------------------------
> s_vogel's Profile: https://forums.novell.com/member.php?userid=141388
> View this thread: https://forums.novell.com/showthread.php?t=481972



0 Likes
s_vogel Absent Member.
Absent Member.

Re: read signature as plain text

Do you do the parsing of the MIME yourself or can you recommend a package/library that handles this well?
0 Likes
Anonymous_User Absent Member.
Absent Member.

Re: read signature as plain text

>
> Do you do the parsing of the MIME yourself or can you recommend a
> package/library that handles this well?


I did not try that because my expectation has been that the Groupwise
client (API) should contain such a method already, because when a
regular user is sending a plain text message, the client does perform
this conversion already. Therefor it would make sense to have this plain
text versionof the signature available by API, or at a least an API call
that converts the HTML signature intoa plain text signature.
0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.