title: Getting error `No module named mime.text` [Python]
body: <p>This code is "suppose" to send an email.</p>
  
  <pre><code>import smtplib
  #SERVER = "localhost"
  
  FROM = 'myEmail@email.com'
  
  TO = ["toEmail@email.com"] # must be a list
  
  SUBJECT = "Hello!"
  
  TEXT = "This message was sent with Python's smtplib."
  
  # Prepare actual message
  
  message = """\
  From: %s
  To: %s
  Subject: %s
  
  %s
  """ % (FROM, ", ".join(TO), SUBJECT, TEXT)
  
  # Send the mail
  
  server = smtplib.SMTP('myserver')
  server.sendmail(FROM, TO, message)
  server.quit()
  </code></pre>
  
  <p>I get this error message.</p>
  
  <pre><code>Traceback (most recent call last):
    File "C:\Users\myCpu\Documents\myFiles\python\test wy.py", line 1, in &lt;module&gt;
      import smtplib
    File "C:\Python27\lib\smtplib.py", line 46, in &lt;module&gt;
      import email.utils
    File "C:/Users/myCpu/Documents/myFiles/python\email.py", line 5, in &lt;module&gt;
  ImportError: No module named mime.text
  </code></pre>
  
  <hr>
  
  <p>Using:</p>
  
  <p>Python 2.7</p>
  
  <p>Windows 7 Professionnal</p>
  
  <p>Gmail (@gmail.com)</p>
  
  <hr>
  
  <p><strong>Can anyone help me with this code?</strong></p>