Return-Path: Delivered-To: apmail-httpd-users-archive@www.apache.org Received: (qmail 62491 invoked from network); 27 Mar 2010 02:17:15 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 27 Mar 2010 02:17:15 -0000 Received: (qmail 563 invoked by uid 500); 27 Mar 2010 02:17:12 -0000 Delivered-To: apmail-httpd-users-archive@httpd.apache.org Received: (qmail 521 invoked by uid 500); 27 Mar 2010 02:17:12 -0000 Mailing-List: contact users-help@httpd.apache.org; run by ezmlm Precedence: bulk Reply-To: users@httpd.apache.org list-help: list-unsubscribe: List-Post: List-Id: Delivered-To: mailing list users@httpd.apache.org Received: (qmail 513 invoked by uid 99); 27 Mar 2010 02:17:12 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 27 Mar 2010 02:17:12 +0000 X-ASF-Spam-Status: No, hits=4.4 required=10.0 tests=AWL,DEAR_SOMETHING,FREEMAIL_ENVFROM_END_DIGIT,FREEMAIL_FROM,HTML_MESSAGE,RCVD_IN_DNSWL_NONE,SPF_PASS,T_TO_NO_BRKTS_FREEMAIL X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: local policy) Received: from [66.196.101.49] (HELO web59308.mail.re1.yahoo.com) (66.196.101.49) by apache.org (qpsmtpd/0.29) with SMTP; Sat, 27 Mar 2010 02:17:04 +0000 Received: (qmail 78904 invoked by uid 60001); 27 Mar 2010 02:16:43 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s1024; t=1269656203; bh=4GGNRxunwwjXc9itunrWqWL5Om7DitmIkwqQVmEnKx4=; h=Message-ID:X-YMail-OSG:Received:X-Mailer:Date:From:Subject:To:MIME-Version:Content-Type; b=rksveHumIFUG54wbHImLShBQ/JZreprmoL/o8+BvDg1qY5E2QiS0T/A3K09irJDXhFKr+xxiU9yxEpWY/kqhnxN2Ur/yXkePND+QhGVBTVGNwDjqDFfOxIzgE8dVMVl7M8pL/vOvwKp5aqnKHwYY3te39isqnk36I1fksNBDv3I= DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Message-ID:X-YMail-OSG:Received:X-Mailer:Date:From:Subject:To:MIME-Version:Content-Type; b=tNs6xPalWSgbWNVpYAUXLzfHkaXxvivuT6Ttwmm+sR1Qn/24LWkjpADL5KEO09xEBk1c4kmOZ0Br7ESnSNx86yEvrjgzT+jBjFGPlEHICq8XrECKSh5ioUKcMDIpYdSkJ/Ru/sb5aWaVSvHQAWaU7NdeM1KKO7lUZTXK892B0WY=; Message-ID: <266922.78895.qm@web59308.mail.re1.yahoo.com> X-YMail-OSG: EsNJd1cVM1lB7fDzrVFwX8ppptcFxvOHmv2zlyXgNWsgwtzv_VILw616f_2LL06Ggv4YuNtegE9iTvnQx_f09FEGuaUOyCM1jWrnTw4VushRlZhWmJCLiHzLRnPBNFFH1GfmyjBAp3Cq1IcFo3zclFXz69_EgqcP3o3Be3vDxywDt76p7SoOdy7X3lr7nNQVL96xKGiiy1dCvCPdVMBAp1Bn49.bcnGIhUtkn6VZOgI.ga2nHpMeSksHUZZvT_GvrIl5OZbW1qVFsa6pfbEAzFgi7TAbvOKubzsirdcbMvecip6VU2TVMv24Vw-- Received: from [124.82.127.147] by web59308.mail.re1.yahoo.com via HTTP; Fri, 26 Mar 2010 19:16:42 PDT X-Mailer: YahooMailClassic/10.0.8 YahooMailWebService/0.8.100.260964 Date: Fri, 26 Mar 2010 19:16:42 -0700 (PDT) From: Lee David To: users@httpd.apache.org MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="0-1869827160-1269656202=:78895" Subject: [users@httpd] How to make the code of PHP[mail()] work? --0-1869827160-1269656202=:78895 Content-Type: text/plain; charset=us-ascii Dear Sir/Madam: Good day. I am the beginner for PHP With MySQL. I would like to learn PHP With MySQL as my hobby. I am trying the code of: mail($to, $subject, $msg, 'From:' . $email); But the code of mail() is not functioning. If anybody is kind enough, please provide some guidances for me to implement a proper setting. For your info, i am using window XP home edition, Apache server 2.0, PHP 5.0 & MYSQL 5.1 as my local testing server. As per your advices, i have allow internet users to use the service of SMTP in windows firewall. >From the review server error log, i be able to observe Warning as below: [Sat Mar 13 13:58:17 2010] [error] [client 127.0.0.1] PHP Warning: mail() [function.mail]: Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in C:\\Program Files\\Apache Group\\Apache2\\test\\report.php on line 30, referer: http://localhost/report_Temp.html If possible, could show me how configure the php.ini and any relevant setting: In my php.ini, i be able to see: [mail function] ; For Win32 only. SMTP = localhost smtp_port = 25 2 weeks ago ; For Win32 only. ;sendmail_from = me@example.com ; For Unix only. You may supply arguments as well (default: "sendmail -t -i"). ;sendmail_path = ; Force the addition of the specified parameters to be passed as extra parameters ; to the sendmail binary. These parameters will always replace the value of ; the 5th parameter to mail(), even in safe mode. ;mail.force_extra_parameters = Thanks. Warm Regards, David Lee --0-1869827160-1269656202=:78895 Content-Type: text/html; charset=us-ascii
Dear Sir/Madam:

Good day. I am the beginner for PHP With MySQL.

I would like to learn PHP With MySQL as my hobby.

I am trying the code of:

mail($to, $subject, $msg, 'From:' . $email);

But the code of mail() is not functioning.

If anybody is kind enough, please provide some guidances for me to implement a
proper setting.

For your info, i am using window XP home edition, Apache server 2.0, PHP 5.0 & MYSQL 5.1 as my local testing server.

As per your advices, i have allow internet users to use the service of SMTP in windows firewall.

>From the review server error log, i be able to observe Warning as below:

[Sat Mar 13 13:58:17 2010] [error] [client 127.0.0.1] PHP Warning: mail() [<a href='function.mail'>function.mail</a>]: Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in C:\\Program Files\\Apache Group\\Apache2\\test\\report.php on line 30, referer: http://localhost/report_Temp.html

If possible, could show me how configure the php.ini and any relevant setting:

In my php.ini, i be able to see:

[mail function]
; For Win32 only.
SMTP = localhost
smtp_port = 25

2 weeks ago

; For Win32 only.
;sendmail_from = me@example.com

; For Unix only. You may supply arguments as well (default: "sendmail -t -i").
;sendmail_path =

; Force the addition of the specified parameters to be passed as extra parameters
; to the sendmail binary. These parameters will always replace the value of
; the 5th parameter to mail(), even in safe mode.
;mail.force_extra_parameters =


Thanks.

Warm Regards,
David Lee


--0-1869827160-1269656202=:78895--