mailing using Php

Discussion in 'PHP' started by j.m.razeed, Jul 22, 2010.

  1. #1
    i want to send feedbacks to my mail in my site. please tell me php code or anyother to send emails..
     
    j.m.razeed, Jul 22, 2010 IP
  2. po_taka

    po_taka Peon

    Messages:
    14
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    0
    #2
    try phpmauler
    http ://phpmailer.worxware.com/
     
    po_taka, Jul 22, 2010 IP
  3. Deacalion

    Deacalion Peon

    Messages:
    438
    Likes Received:
    11
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Do you want to know how to send an e-mail or how to setup a mailing list? (you should use white listed SMTP servers for a mailing list)

    If you are just sending yourself e-mails, then you can use something like this:
    
    <?php    
        $to = 'me@myDomain.co.uk';
        $from = 'feedback@myDomain.co.uk';
        
        $subject = 'Feedback from Site';
        $message = 'Form / Feedback data here';
    
        $headers = 'From: ' . $from;
        
        mail($to, $subject, $message, $headers) || die('Mail failed to send');
        
        echo 'Mail sent ok';
    ?>
    
    PHP:
     
    Deacalion, Jul 22, 2010 IP
  4. caciocode

    caciocode Peon

    Messages:
    65
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    0
    #4
    caciocode, Jul 23, 2010 IP