PyMails
Required
Send mail
from email.mime.text import MIMEText
from email.mime.multipart import MIMEMultipart
from PyMails import *
smtp_server = ''
port = ''
sender_email = ''
password = ''
receiver_email = ''
## Html form
msg = MIMEMultipart('alternative')
msg['Subject'] = 'Test mail'
msg['From'] = sender_email
msg['To'] = receiver_email
html = open('./html/mail.html','r+').read()
msg.attach(MIMEText(html, 'html'))
## Without html form
msg = MIMEText('Test')
msg['Subject'] = 'Test mail'
msg['From'] = sender_email
msg['To'] = receiver_email
send_mail(smtp_server,port,sender_email,password,receiver_email,msg);
Connection test
connection_test(smtp_server,port,sender_email,password)
Change Log
0.0.5 (05.04.2021)
- Add connection test
0.0.1 (04.04.2021)
- First Release
Metadata
Release files for PyMails 0.0.5
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| PyMails-0.0.5.tar.gz | 2.8 kB | Details |
Release files / PyMails-0.0.5.tar.gz
| Download URL | PyMails-0.0.5.tar.gz |
|---|---|
| Size | 2.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
229d43a5343e17798a4db4311733b731af342dfc7cf1931e870079dbcb6af8a2
|
|
BLAKE2b-256 checksum How to use checksums |
3eff8f7c23043198f38939d87b94c67e079000a84f52a6eeada3b7a0157418cf
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.1 importlib_metadata/3.7.2 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.9.2
|