Python built email message doesn't support OutLook Express

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • praba kar

    #1

    Python built email message doesn't support OutLook Express

    Dear All,

    I am working in web based email system project.
    Here I try to build email message
    from scratch. I used below code to build email
    message

    msg = email.MIMEBase( 'text','html')
    msg['Return-Path'] = user+'@'+domain
    msg['Date'] = formatdate(loca ltime=1)
    msg['Subject'] = subject
    msg['From'] = from_name
    msg['To'] = to
    msg['Cc'] = cc
    msg.set_payload ("Body of the email messagge")
    fh = os.popen('/bin/sendmail %s'% (eachid),'w')
    fh.write(msg.as _string())
    fh.close()

    This code will build plain email message properly.
    But after building the message. If a email user
    download this mail through out look express then
    this email message will display without any alignment.
    If a user type 3 paragraph message
    outlook express display as a single line. What
    could be problem?. Kindly let me know ASAP

    regards
    Prabahar




    _______________ _______________ _______________ __________
    Too much spam in your inbox? Yahoo! Mail gives you the best spam protection for FREE! http://in.mail.yahoo.com
  • Sybren Stuvel

    #2
    Re: Python built email message doesn't support OutLook Express

    praba kar enlightened us with:[color=blue]
    > This code will build plain email message properly.[/color]

    It's not a plain email message. It's an html email without a plain
    text part. Highly annoying to many people.
    [color=blue]
    > But after building the message. If a email user download this mail
    > through out look express then this email message will display
    > without any alignment.[/color]

    Post the msg.as_string() output so we can see whay you're sending.

    Sybren
    --
    The problem with the world is stupidity. Not saying there should be a
    capital punishment for stupidity, but why don't we just take the
    safety labels off of everything and let the problem solve itself?
    Frank Zappa

    Comment

    • Diez B. Roggisch

      #3
      Re: Python built email message doesn't support OutLook Express

      That is not what Sybren requested - we need the message text. If you
      send html, make sure your paragraphs are html paragraphs (enclosed in
      <p>-tags) and not pure whitespace, as html ignores these.



      Diez

      Comment

      • Dennis Lee Bieber

        #4
        Re: Python built email message doesn't support OutLook Express

        On Wed, 31 Aug 2005 05:42:54 +0100 (BST), praba kar
        <prabapython@ya hoo.co.in> declaimed the following in comp.lang.pytho n:
        [color=blue]
        >
        > --- "Diez B. Roggisch" <deets@web.de > wrote:
        >[color=green]
        > > That is not what Sybren requested - we need the
        > > message text. If you
        > > send html, make sure your paragraphs are html
        > > paragraphs (enclosed in
        > > <p>-tags) and not pure whitespace, as html ignores
        > > these.
        > >[/color]
        > I am sending text message as a paragraph
        >[/color]
        And you /still/ haven't shown us the exact contents of that
        "paragraph" , including all "non-printables".
        --[color=blue]
        > =============== =============== =============== =============== == <
        > wlfraed@ix.netc om.com | Wulfraed Dennis Lee Bieber KD6MOG <
        > wulfraed@dm.net | Bestiaria Support Staff <
        > =============== =============== =============== =============== == <
        > Home Page: <http://www.dm.net/~wulfraed/> <
        > Overflow Page: <http://wlfraed.home.ne tcom.com/> <[/color]

        Comment

        • Robert Kern

          #5
          Re: Python built email message doesn't support OutLook Express

          praba kar wrote:[color=blue]
          > --- "Diez B. Roggisch" <deets@web.de > wrote:
          >[color=green]
          >>That is not what Sybren requested - we need the
          >>message text. If you
          >>send html, make sure your paragraphs are html
          >>paragraphs (enclosed in
          >><p>-tags) and not pure whitespace, as html ignores
          >>these.[/color]
          >
          > I am sending text message as a paragraph[/color]

          We. Need. To. See. The. Actual. String.

          Otherwise, we cannot help you.

          --
          Robert Kern
          rkern@ucsd.edu

          "In the fields of hell where the grass grows high
          Are the graves of dreams allowed to die."
          -- Richard Harter

          Comment

          Working...