Re: PureSMTP library : mail & attachments (AUTH supported)
Posted: Wed Aug 04, 2010 1:45 am
@gnozal
Hi, your library is fantastic, but unfortunately I have hit a hard stone with it.
I'm trying to compose a multi-part html email with in-line images and I can not do so unless you allow Pure_SMTP to remove the default content type and transfer encoding.
When I send an email with your library it sends by default the headers for content type and transfer encoding:
I tried to do: PureSMTP_SetContentType("") but logically it defaults to 'Content-Type: text/plain; charset="iso-8859-1"', and as far as I have been able to see the 'Content-Transfer-Encoding: 7bit' can not be disabled either and it sits there by default.
In order to send a multi-part email with html and in-line images, the header structure must be like the one below, with the content type at the very end of the header list, and with no encoding which I specifiy for each section of the email individually.
Setting the PureSMTP_SetContentType to "Content-Type: multipart/alternative;" does not fix the issue, as long as those two headers remain there, with them being sent by default I can not make the email display at all on the email client. (outlook/thunderbird)
This is a big issue for me, could you please add some switch somewhere so the default content type and transfer encodings can be disabled if one needs to?
Hi, your library is fantastic, but unfortunately I have hit a hard stone with it.

I'm trying to compose a multi-part html email with in-line images and I can not do so unless you allow Pure_SMTP to remove the default content type and transfer encoding.
When I send an email with your library it sends by default the headers for content type and transfer encoding:
Code: Select all
From - Wed Aug 04 02:11:46 2010
X-Account-Key: account4
X-UIDL: UID45-1279760133
X-Mozilla-Status: 0001
X-Mozilla-Status2: 00000000
X-Mozilla-Keys:
Return-Path: <christian.uceda@test.lcl>
X-Original-To: test@test.lcl
Delivered-To: test@test.lcl
Received: from Apollo (brutus.test.lcl [192.168.249.80])
by barask10.test.lcl (Postfix) with SMTP id 298B928451;
Wed, 4 Aug 2010 02:11:47 +0200 (CEST)
From: Christian Uceda <christian.uceda@test.lcl>
To: <test@test.lcl>
Subject: Test Email X
X-Mailer: PureSMTP
MIME-Version: 1.0
Content-Type: text/plain; charset="iso-8859-1" <------------ (Need to remove)
Content-Transfer-Encoding: 7bit <------------ (Need to remove)
Message-Id: <20100804001148.298B928451@barask10.test.lcl>
Date: Wed, 4 Aug 2010 02:11:47 +0200 (CEST)
In order to send a multi-part email with html and in-line images, the header structure must be like the one below, with the content type at the very end of the header list, and with no encoding which I specifiy for each section of the email individually.
Code: Select all
From - Wed Aug 04 02:11:46 2010
X-Account-Key: account4
X-UIDL: UID45-1279760133
X-Mozilla-Status: 0001
X-Mozilla-Status2: 00000000
X-Mozilla-Keys:
Return-Path: <christian.uceda@test.lcl>
X-Original-To: test@test.lcl
Delivered-To: test@test.lcl
Received: from Apollo (brutus.test.lcl [192.168.249.80])
by barask10.test.lcl (Postfix) with SMTP id 298B928451;
Wed, 4 Aug 2010 02:11:47 +0200 (CEST)
From: Christian Uceda <christian.uceda@test.lcl>
To: <test@test.lcl>
Subject: Test Email X
X-Mailer: PureSMTP
MIME-Version: 1.0
Message-Id: <20100804001148.298B928451@barask10.test.lcl>
Date: Wed, 4 Aug 2010 02:11:47 +0200 (CEST)
Content-Type: multipart/alternative; <------------ (Good)
boundary="------------040006060302020507070601" <------------ (Good)
This is a big issue for me, could you please add some switch somewhere so the default content type and transfer encodings can be disabled if one needs to?
