0

I got this issue with icalendar, it doesn't show the attachment and the confirmation button when sent to gmail,yahoo, aoutlook.com. it was working before without html message and multipart/mixed header. now when i recieve the email it only show me the the text of the calendar, it doesn't recognize it. Content-type: multipart/mixed; boundary="982f8d486c3cbed0e28b314e7a433c3d"

--982f8d486c3cbed0e28b314e7a433c3d
Content-Type: multipart/alternative; boundary="19f4b0e33c6f735ae6f858b1df7b72f2"

--19f4b0e33c6f735ae6f858b1df7b72f2
Content-Type: text/calendar; method=REQUEST; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

BEGIN:VCALENDAR
VERSION:2.0
PRODID:-//Testa//Tes//EN
METHOD:REQUEST
BEGIN:VEVENT
UID:20150914T205515-998107994-domain.com
DTSTAMP:20150914T205515
DTSTART:20150915T195500Z
DTEND:20150915T195500Z
ORGANIZER;CN=soy:MAILTO:admin@adminm.org
ATTENDEE;ROLE=REQ-PARTICIPANT;PARTSTAT=NEEDS-ACTION;RSVP=TRUE;CN=xxx.yyy@gmail.com:MAILTO:xxx.yyy@gmail.com
LOCATION:hj
SUMMARY:Rendez-vous 
BEGIN:VALARM
TRIGGER:-PT15M
ACTION:DISPLAY
DESCRIPTION:Reminder
END:VALARM
END:VEVENT
END:VCALENDAR

--19f4b0e33c6f735ae6f858b1df7b72f2--
--982f8d486c3cbed0e28b314e7a433c3d
Content-Type: application/ics; name="Rv-invite.ics"
Content-Disposition: attachment; filename="Rv-invite.ics"
Content-Transfer-Encoding: base64
X-Mailer: Microsoft Office Outlook 12.0
X-Mailer: CakePHP Email
Date: Mon, 14 Sep 2015 20:55:16 +0200
Message-ID: <55f71814db484f8fa8923d8664ca69fc@localhost>
Subject: Rendez-vous 
MIME-Version: 1.0
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: 8bit

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
<html>
<head>
        <title>Emails/html</title>
</head>
<body>

<p>Dear,</p>

<p>Mr xxx sent an appointment</p>
</body>
</html>

thanks in advance.

Monologie
  • 11
  • 3

1 Answers1

0

Well your second body part has 2 content-type headers:

Content-Type: application/ics; name="Rv-invite.ics"
Content-Disposition: attachment; filename="Rv-invite.ics"
Content-Transfer-Encoding: base64

and

Content-Type: text/html; charset=UTF-8
 Content-Transfer-Encoding: 8bit

It looks like some of the headers also belong to the top level and not in the body part:

X-Mailer: Microsoft Office Outlook 12.0
X-Mailer: CakePHP Email
Date: Mon, 14 Sep 2015 20:55:16 +0200
Message-ID: <55f71814db484f8fa8923d8664ca69fc@localhost>
Subject: Rendez-vous 
MIME-Version: 1.0

See also this post about the correct MIME structure to use in general: Multipart email with text and calendar: Outlook doesn't recognize ics

Community
  • 1
  • 1
Arnaud Quillaud
  • 4,420
  • 1
  • 12
  • 8