Page 1 of 1
.eml-parser
Posted: Thu Nov 21, 2024 10:08 am
by artnat
Does anybody know an eml-parser to apply in purebasic, and how to embody it into the code?
Re: .eml-parser
Posted: Thu Nov 21, 2024 11:58 am
by Axolotl
Have you searched for it?
Keep in mind that EML files are saved in plain text format and you can also open these EML files with popular text editors.
So it should be easy to do it by yourself and don't forget to share the results

Re: .eml-parser
Posted: Thu Nov 21, 2024 12:25 pm
by NicTheQuick
The most complex part is to parse it correctly. There can be all kinds of shenanigans regarding UTF-7 character encoding, multipart messages, base64 encoded data and stuff like that.
So it really is complicated if you want to make it properly and I don't think it is a good idea to reinvent the wheel here. Just find libraries that do that for you. There should be DLLs on Windows that can do that. And on Linux it is as easy as installing packages like `libemail`, `libetpan` or `libgmime-3.0-dev` and then convert the C headers files into something suitable for Purebasic. I know that this is not an easy task on its own but at least you only have to do it once and you do not need to care a lot about updating that library.