SitePoint Sponsor

User Tag List

Results 1 to 6 of 6

Thread: E-Mail Headers

  1. #1
    The Hiding One lynlimz's Avatar
    Join Date
    Jul 2000
    Location
    Singapore
    Posts
    2,103
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    E-Mail Headers

    Hi,

    I've been very puzzled with some email problems using mail().
    I send emails through that..but users with a specific host ...(sourceforge.net) don't receive it.

    I suspect its the headers.
    But whats with the headers?
    Other users receive it with no problem.

    $headers = "From: Name of Script<$sender>\n";
    $headers .= "X-Mailer: Name of Script\n";
    $headers .= "bcc: $recipient\n";

    mail("","$subject","$message","$headers");

    I'm sending email via BCC so users can't view each other's email addresses.

    Any help would be greatly appreciated. thanks
    "Imagination is more important than knowledge. Knowledge is limited. Imagination encircles the world."
    -- Albert Einstein

  2. #2
    Victory shall be mine tubedogg's Avatar
    Join Date
    Mar 2001
    Location
    Medina, OH
    Posts
    440
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Some (mail server-level) spam-checking programs disregard any email that doesn't have the intended recipient's email address in the to: field. This might be what sourceforge's server is doing. I think it's stupid but hey who am I.
    Kevin

  3. #3
    The Hiding One lynlimz's Avatar
    Join Date
    Jul 2000
    Location
    Singapore
    Posts
    2,103
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    grrr..thats dumb
    well..okay. so my workaround would be to include a To field?
    hmm...

    how do those mass emailling newsletter programs work then?
    "Imagination is more important than knowledge. Knowledge is limited. Imagination encircles the world."
    -- Albert Einstein

  4. #4
    SitePoint Wizard silver trophy Karl's Avatar
    Join Date
    Jul 1999
    Location
    Derbyshire, UK
    Posts
    4,411
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Just put your own email address in the To portion of the mail() function call - that's how pretty much all mass email programs work and at least you get a copy of the email you sent out too.
    Karl Austin :: Profile :: KDA Web Services Ltd.
    Business Web Hosting :: Managed Dedicated Hosting
    Call 0800 542 9764 today and ask how we can help your business grow.

  5. #5
    The Hiding One lynlimz's Avatar
    Join Date
    Jul 2000
    Location
    Singapore
    Posts
    2,103
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    ah..cool. Thansk Karl
    "Imagination is more important than knowledge. Knowledge is limited. Imagination encircles the world."
    -- Albert Einstein

  6. #6
    <? echo "Kick me"; ?> petesmc's Avatar
    Join Date
    Nov 2000
    Location
    Hong Kong
    Posts
    1,508
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi,

    1. The To field must point to their email otherwise it can be blocked.

    2. The Header bcc should be Bcc, capital B in some cases with PHP on Win systems.

    3. Just use a mailing list program and then you don't have to worry about this as everyone gets their own personal email.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •