09-22-2010, 12:57 AM | #1 |
Junior Member
Posts: 3
Karma: 10
Join Date: Sep 2010
Device: Kindle
|
Converting HTML emails?
Hi folks.
I pay to subscribe to an email newsletter that comes in HTML format with image links -- so it expects a browser to get the images from the Internet. I'd really like to be able to read this (quite long) daily newsletter on my Kindle, and ideally just turn up there. I haven't got anything satisfactory yet. So far all I've been printing from my browser to A5 PDFs and reading those, but Kindle isn't great for PDFs and I end up in landscape mode. I found the browser clipped the width on any smaller page size, but even at A5 the text is too small to read comfortably. The big cause of the problem is they format the pages using HTML tables set to 700 pixels. I know, how 1996 of them, but I suppose they have to deal with ancient HTML renderers in dinosaurs like Outlook 2003. So anyone have any thoughts on how to automatically reformat these? There is an online link sent in each of the emails each day. I suppose I could write a quick Perl script to scrape that link out of the emails and kick off some conversion process on that link, but it shares the same problems. I'll also talk to the newsletter's owners and see if they can offer a (password protected) full RSS feed for subscribers. PS: In case you care, the newsletter is http://www.crikey.com.au/ but not the sample they give looks nothing like what is delivered these days! |
09-22-2010, 02:31 AM | #2 |
himself
Posts: 576
Karma: 11226
Join Date: May 2010
Device: Kobo
|
I see numerous ways to do that. The best should be the most
simple one. As you receive mails, you could just make them available as web page. You need home router with wifi, one node to have web server on and k3, without any further app or whatever, since it shows html content. The question is what to use to put mail together on one page. Something like "cat mail.html second_mail.html > /dir/to/server/mail.html". One script in cron might regularly iterate the whole directory with "cd dir; cat * ...". Web server could be one of light ones, as nginx or similar. As soon as you start to investigate, you will find your own way to do that. |
09-27-2010, 09:19 PM | #3 | |
Junior Member
Posts: 3
Karma: 10
Join Date: Sep 2010
Device: Kindle
|
Quote:
Thanks for the idea. I now have a little script that updates a redirect to the latest edition, based on the content of the email I receive. |
|
09-27-2010, 09:33 PM | #4 |
Author's pet-geek
Posts: 933
Karma: 1040670
Join Date: Sep 2010
Location: North Queensland, Australia
Device: Kindle 3 Wifi, Onyx Boox M96
|
There's a few ways - you might want to explore also using ripMIME if you have a linux/unix box. Use ripMIME to break open the email, pull the HTML text out and then push it through PHP with strip_tags().
Paul. |
09-27-2010, 09:34 PM | #5 |
Junior Member
Posts: 3
Karma: 10
Join Date: Sep 2010
Device: Kindle
|
The HTML actually renders just fine on the Kindle, the problem being the inline images that need to be fetched over the network. How can you do HTML on the Kindle and include images? I've tried a few different approaches without success.
|
09-27-2010, 10:03 PM | #6 |
Author's pet-geek
Posts: 933
Karma: 1040670
Join Date: Sep 2010
Location: North Queensland, Australia
Device: Kindle 3 Wifi, Onyx Boox M96
|
That's a much tougher problem.
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Converting PDF to HTML | Nirf | Calibre | 7 | 06-24-2010 08:51 AM |
Error when converting html to LRF | Amalthia | Calibre | 1 | 11-18-2009 09:07 AM |
Converting from html | mysweety | Calibre | 16 | 09-23-2009 08:20 AM |
Converting HTML to Mobi? | Sonist | Calibre | 5 | 02-10-2009 01:23 PM |
Converting CHM to Html | Tahras Rastah | Workshop | 0 | 01-16-2008 05:11 PM |