Skip to main content
Stack Overflow
  1. About
  2. For Teams

Timeline for How do I integrate a HTML code in a Python Script?

Current License: CC BY-SA 4.0

22 events
when toggle format what by license comment
Jun 10, 2019 at 1:04 vote accept Piyush Patil
S Jun 10, 2019 at 0:03 history bounty ended Community Bot
S Jun 10, 2019 at 0:03 history notice removed Community Bot
Jun 8, 2019 at 23:46 comment added Mike @error2007s - see my answer on integrating HTML code into python for merging the HTML report from your data frame
Jun 8, 2019 at 6:40 answer added Mike timeline score: 2
Jun 3, 2019 at 13:07 answer added delica timeline score: -2
Jun 2, 2019 at 13:23 history edited Piyush Patil CC BY-SA 4.0
added 1443 characters in body
Jun 2, 2019 at 13:04 answer added Samuel Cooper timeline score: 10
S Jun 1, 2019 at 22:17 history bounty started Piyush Patil
S Jun 1, 2019 at 22:17 history notice added Piyush Patil Draw attention
May 30, 2019 at 19:27 history edited Piyush Patil
edited tags
May 30, 2019 at 16:33 comment added Piyush Patil The HTML code I have created is in a different file so my question is how do I integrate that HTML code into the above Python script while sending the email out.
May 30, 2019 at 16:15 comment added Ricky Kim Actually, I feel like the code you put on question is irrelevant/not the part you're asking: there are no html you're trying to send at all in the code.
May 30, 2019 at 16:07 comment added Ricky Kim That was the correct code... change MIMEText(message, 'plain') to MIMEText(message, 'html')
May 30, 2019 at 16:06 comment added Piyush Patil Do not worry about that I removed that line
May 30, 2019 at 16:05 history edited Piyush Patil CC BY-SA 4.0
deleted 32 characters in body
May 30, 2019 at 16:02 comment added Ricky Kim Is the script you attached in question the actual one you're using? because it has the html part commented out.
May 30, 2019 at 15:59 comment added Piyush Patil Yes that email is working and looks perfect in the inbox when I test it out. The HTML email is not a issue integrating that HTML code with this Python script is issue
May 30, 2019 at 15:57 comment added Ricky Kim Have you tried manually sending html email and see if it works? Because a lot of formatting (CSS) don't work in emails.
May 30, 2019 at 15:50 comment added Piyush Patil Yes but the email I get is very plane in format see this sample imgur.com/hCoCrGu
May 30, 2019 at 15:47 comment added Ricky Kim It looks like you already have the code for it: MIMEText(email,'html')?
May 30, 2019 at 15:36 history asked Piyush Patil CC BY-SA 4.0
toggle format

AltStyle によって変換されたページ (->オリジナル) /