Mail attachment questions...

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

    #1

    Mail attachment questions...

    Hi Pedro,

    I know i have to read a lot. :) But sometimes
    i need a little help from my friends, because i
    am the only one in my environment that experiments
    with php who could help me.. :(

    Few questions though:

    I cannot imagine that sending html is too much
    for automated mail, or shouldn't i take this
    too literally?

    Would it be better to send a mail with an image in it
    with an absolute url instead of attachment? Then renaming
    files is not-done anymore, but it keeps the mail small...
    Well thanks anyway!!

    greetings
  • Manuel Lemos

    #2
    Re: Mail attachment questions...

    Hello,

    on 12/29/2004 08:58 AM knoak said the following:[color=blue]
    > I cannot imagine that sending html is too much
    > for automated mail, or shouldn't i take this
    > too literally?[/color]

    You should not send HTML only messages, as your messages may be blocked
    for seeming like SPAM.

    What you need to do is to compose a multipart/alternative message that
    includes both an HTML part and an alternative plain text part.

    [color=blue]
    > Would it be better to send a mail with an image in it
    > with an absolute url instead of attachment? Then renaming
    > files is not-done anymore, but it keeps the mail small...
    > Well thanks anyway!![/color]

    It depends on the importance of the images for your messages. Most
    modern webmail and e-mail clients tend to not show remote images in the
    messages as it may be a beacon to invade the user privacy to determine
    when the message was received.

    You can include images within the message body that are treated as part
    of the HTML message using multipart/related message parts.

    This is a little complicated but fortunately there are ready to use
    classes to help you compose and send proper HTML messages, like for
    instance this MIME message class:

    http://www.phpclasses.org/mimemessage


    --

    Regards,
    Manuel Lemos

    PHP Classes - Free ready to use OOP components written in PHP
    http://www.phpclasses.org/

    PHP Reviews - Reviews of PHP books and other products
    http://www.phpclasses.org/reviews/

    Metastorage - Data object relational mapping layer generator

    Comment

    • Manuel Lemos

      #3
      Re: Mail attachment questions...

      Hello,

      on 12/29/2004 08:58 AM knoak said the following:[color=blue]
      > I cannot imagine that sending html is too much
      > for automated mail, or shouldn't i take this
      > too literally?[/color]

      You should not send HTML only messages, as your messages may be blocked
      for seeming like SPAM.

      What you need to do is to compose a multipart/alternative message that
      includes both an HTML part and an alternative plain text part.

      [color=blue]
      > Would it be better to send a mail with an image in it
      > with an absolute url instead of attachment? Then renaming
      > files is not-done anymore, but it keeps the mail small...
      > Well thanks anyway!![/color]

      It depends on the importance of the images for your messages. Most
      modern webmail and e-mail clients tend to not show remote images in the
      messages as it may be a beacon to invade the user privacy to determine
      when the message was received.

      You can include images within the message body that are treated as part
      of the HTML message using multipart/related message parts.

      This is a little complicated but fortunately there are ready to use
      classes to help you compose and send proper HTML messages, like for
      instance this MIME message class:

      http://www.phpclasses.org/mimemessage


      --

      Regards,
      Manuel Lemos

      PHP Classes - Free ready to use OOP components written in PHP
      http://www.phpclasses.org/

      PHP Reviews - Reviews of PHP books and other products
      http://www.phpclasses.org/reviews/

      Metastorage - Data object relational mapping layer generator

      Comment

      Working...