[PHP] Problems with mail function

2006-10-24 Thread Ricardo Ríos

Hi wizards, I 'm trying to use mail function in PHP, but this function don't
send the email , I have a server with postfix. Does somebody know how to
send an email with php and postfix. Thanks in advance.


Re: [PHP] Problems with mail function

2006-10-24 Thread John Nichel

Ricardo Ríos wrote:
Hi wizards, I 'm trying to use mail function in PHP, but this function 
don't

send the email , I have a server with postfix. Does somebody know how to
send an email with php and postfix. Thanks in advance.



Does your install of postfix have a sendmail wrapper?  Is it in the 
normal sendmail location (/usr/bin/sendmail)?  Is this on the same 
machine as your php install?  Does the user in which Apache is running 
as have permission to invoke the sendmail wrapper?


--
John C. Nichel IV
Programmer/System Admin (ÜberGeek)
Dot Com Holdings of Buffalo
716.856.9675
[EMAIL PROTECTED]

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Problems with mail function

2006-10-24 Thread Jochem Maas
John Nichel wrote:
 Ricardo Ríos wrote:
 Hi wizards, I 'm trying to use mail function in PHP, but this function
 don't
 send the email , I have a server with postfix. Does somebody know how to
 send an email with php and postfix. Thanks in advance.

 
 Does your install of postfix have a sendmail wrapper?  Is it in the
 normal sendmail location (/usr/bin/sendmail)?  Is this on the same
 machine as your php install?  Does the user in which Apache is running
 as have permission to invoke the sendmail wrapper?

what does the error msg say? is display_errors on?
is error_reporting() set to E_ALL? ...

does he eat cheese? :-)

 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Problems with mail function

2006-10-24 Thread Chris

Ricardo Ríos wrote:
Hi wizards, I 'm trying to use mail function in PHP, but this function 
don't

send the email , I have a server with postfix. Does somebody know how to
send an email with php and postfix. Thanks in advance.


Create a phpinfo page and make sure the 'sendmail_path' is set.

If that's set, you can just use php mail() as normal. The mail() command 
doesn't care about what sort of MTA it uses, it just cares it knows 
where it is and how to access it.


--
Postgresql  php tutorials
http://www.designmagick.com/

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Problems with mail function

2004-11-08 Thread Pete

I have a problem with a standard mail() function.  

If I put a short message ( test ) into it, then the email is sent.  

If I put a longer  message in (Visitors name and address collected from
webpage), then the mail is not sent.  

No error message is generated, the mail just doesn't arrive.

The client has PHP Version 4.3.1 on Windows NT localhost 5.2 build 3790 
-- 
Pete Clark

http://www.hotcosta.com
http://www.spanishholidaybookings.com

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Problems with mail function

2004-11-08 Thread Jason Wong
On Monday 08 November 2004 08:23, Pete wrote:
 I have a problem with a standard mail() function.

 If I put a short message ( test ) into it, then the email is sent.

 If I put a longer  message in (Visitors name and address collected from
 webpage), then the mail is not sent.

So you're suspecting size is the problem? Have you tried to figure out what 
size limit is?

-- 
Jason Wong - Gremlins Associates - www.gremlins.biz
Open Source Software Systems Integrators
* Web Design  Hosting * Internet  Intranet Applications Development *
--
Search the list archives before you post
http://marc.theaimsgroup.com/?l=php-general
--
/*
In the long run we are all dead.
  -- John Maynard Keynes
*/

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Problems with mail() function

2001-07-11 Thread rodrigo

Hello. I wrote a routine that queries a table (Mysql) to pull about 300
records and record their emails. I iterate over this recorset invoking
the mail() function to send an email for each record in this recordset.

The problem is that on my providers server, there is a big delay before
the script end execution. When it takes too long I hit the stop button
on the browser, but when I do this the users receive the same email
twice.

Why is this happening?
-- 

Ivan R. Quintero E.* (507)228-3477  
Aptdo 1263 * (507)228-9105
Balboa, Ancon  * 612-1103
Republic of Panama * 


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] Problems with mail() function

2001-05-23 Thread Kevin Fogleman

The problems that I'm having with the mail function stem from the extra
arguments that I'm trying to pass it.  What I'm trying to do is write a
script to mail links to interesting stories to other people.  In doing this,
I want to make the mail appear that it came from the e-mail address of the
person who wanted to send the link.  So, what I've tried so far is this:

$message_subject=This message is a test;
$extraparams=From:
.$HTTP_POST_VARS['youraddress'].\nReply-To:.$HTTP_POST_VARS['youraddress'
].\nX-Mailer: PHP/. phpversion();

$message=$message_header.$HTTP_POST_VARS['message'].$message_footer;
$success=mail($HTTP_POST_VARS['email'], $message_subject, $message,
$extra_params)
   or die(Whoops, looks like mail() isn't configured in
this installation of PHP!);

The message that I recieve when I run this script has a From: field
reading as the user that the script is running under on the web server, and
I recieve a blank message body, as well as no subject.

I decided to try using the mail() function with just the first three
arguments (i.e. the destination address, the subject, and the message body),
and it kind of worked, meaning that it sent me a message with the correct
subject filled out, and the correct message body, but it was still coming
from the same address, the name of the web server user.  Can someone help me
with placing the correct args in the 4th parameter to get mail() or Sendmail
or whatever to send a message with the correct return address and From:
field?

Thank you,

Kevin Fogleman



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Problems with mail() function

2001-05-23 Thread Tolga \thorr\ Orhon

I had smilar problems before and found out that I missed some \ns. It
seems that you missed a \n at the end of headers. That might be a reason.
Another solution might be replacing \ns with \r\n. I heard in newsgroups
and in some documentations that this might be problem in some systems.

I recommend to read the source of message after you get it. It is a nce way
to debug problems and gives out lots of information. (correct headres,
messages etc..)

Yours,

--
Tolga 'thorr' Orhon

Kevin Fogleman [EMAIL PROTECTED] wrote in message
9egjrq$r15$[EMAIL PROTECTED]">news:9egjrq$r15$[EMAIL PROTECTED]...
 The problems that I'm having with the mail function stem from the extra
 arguments that I'm trying to pass it.  What I'm trying to do is write a
 script to mail links to interesting stories to other people.  In doing
this,
 I want to make the mail appear that it came from the e-mail address of the
 person who wanted to send the link.  So, what I've tried so far is this:

 $message_subject=This message is a test;
 $extraparams=From:

.$HTTP_POST_VARS['youraddress'].\nReply-To:.$HTTP_POST_VARS['youraddress'
 ].\nX-Mailer: PHP/. phpversion();

 $message=$message_header.$HTTP_POST_VARS['message'].$message_footer;
 $success=mail($HTTP_POST_VARS['email'], $message_subject, $message,
 $extra_params)
or die(Whoops, looks like mail() isn't configured
in
 this installation of PHP!);

 The message that I recieve when I run this script has a From: field
 reading as the user that the script is running under on the web server,
and
 I recieve a blank message body, as well as no subject.

 I decided to try using the mail() function with just the first three
 arguments (i.e. the destination address, the subject, and the message
body),
 and it kind of worked, meaning that it sent me a message with the correct
 subject filled out, and the correct message body, but it was still coming
 from the same address, the name of the web server user.  Can someone help
me
 with placing the correct args in the 4th parameter to get mail() or
Sendmail
 or whatever to send a message with the correct return address and From:
 field?

 Thank you,

 Kevin Fogleman



 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 To contact the list administrators, e-mail: [EMAIL PROTECTED]




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] Problems with mail function

2001-03-14 Thread Kike

Hi,
I have a seious problem with the mail function. It does not send the emails.
It returns 1 but does not send them. I think it may be a problem with
sendmail permissions. Can you help me? Please.


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Problems with mail function

2001-03-14 Thread Colin May


Quoting Kike (Wed, Mar 14, 2001 at 11:59:32AM -)
 Hi,
 I have a seious problem with the mail function. It does not send the emails.
 It returns 1 but does not send them. I think it may be a problem with
 sendmail permissions. Can you help me? Please.

What do the sendmail mail logs say?  if you havent got access to them, ask 
someone who has?

-- 

Colin May  | "its an illusion, its a game, a reflection of
mailto:[EMAIL PROTECTED]  | someone elses name" - abacab, genesis
http://www.wibble.org.uk   | http://www.abacab.org.uk


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Problems with mail function

2001-03-14 Thread stas

I have the same problem. Mail function works fine on my NT development box,
but when I transfer files over to Unix, it doesn't, as if mail goes into the
void. The only setting you need on Unix is the sendmail path, no? SMTP and
sendmail_from are not required and are ignored, is that correct?


stas


- Original Message -
From: "Colin May" [EMAIL PROTECTED]
To: "Kike" [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: Wednesday, March 14, 2001 11:01 AM
Subject: Re: [PHP] Problems with mail function



 Quoting Kike (Wed, Mar 14, 2001 at 11:59:32AM -)
  Hi,
  I have a seious problem with the mail function. It does not send the
emails.
  It returns 1 but does not send them. I think it may be a problem with
  sendmail permissions. Can you help me? Please.

 What do the sendmail mail logs say?  if you havent got access to them, ask
 someone who has?




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]