Menu
  • HOME
  • TAGS

How to parse email text (bash)

bash,email,mime,quoted-printable

Okay, I'll bite. The data is quoted-printable, and we want the plain text version. So let's use Perl, which already has code for this. #!/usr/bin/perl use strict; use PerlIO::via::QuotedPrint; # Open input file through quoted-printable filter $ARGV[0] ne "" or die "No file specified"; open(IN, '<:via(QuotedPrint)', $ARGV[0]) or die "Could...

Random HTML characters being encoded in emails

php,utf-8,ascii,html-email,quoted-printable

My guess is since that's a closing "tr" that shouldn't be there (you have another right after it), some friendly html parser is "helping" you by changing from being a tag into some normal string. Another thought: See here: https://support.sendgrid.com/hc/en-us/articles/200182068-HTML-Formatting-Issues Some mail clients, such as Outlook and Thunderbird, appear to...

UTF-8 quoted-printable, multiline subject for Thunderbird?

utf-8,multiline,thunderbird,email-headers,quoted-printable

When I ask python to create an email with that subject, here's what it does: $ python Python 2.7.9 (default, Mar 1 2015, 18:22:53) [GCC 4.9.2] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> from email.message import Message >>> from email.header import Header >>> msg =...

Using a Java SOAP service breaks javax.mail's quoted printable mail encapsulation

java,soap,jax-ws,javax.mail,quoted-printable

I believe this is because of this bug in JAX-WS (allegedly fixed in Java 7). JAX-WS uses JAF to introduce a DataHandler for type text/plain that does not respect the character set (i.e. text/plain; charset="utf-8". When the JAX-WS class is loaded, this is used rather than the text/plain handler within...

Rails Mailer quoted-printable replace = by =3D

ruby-on-rails,encoding,actionmailer,quoted-printable

I could be wrong, but I don't think you can have just example.com/logo.gif for an image src in html emails. You need to specify the protocol -- http://example.com/logo.gif. At least Apple Mail is this way.