This may be a dumb question, but have you verified your environment is actually
being set?

Run something like `/bin/env` after making your calls to setenv, and check the
output?

Of course you'd have to do this from the web script and not from the command
line... Sendmail had some options (like overriding the from address) that
required the user id of the account attempting this to be in a config file of
trusted addresses I think - or something similar...

And php can be configured not to export certain env's too...

worth a check if you haven't already.

hth

m/

> -----Original Message-----
> From: Giacomo A. Catenazzi [mailto:[EMAIL PROTECTED]
> Sent: January 29, 2004 12:46 AM
> To: Mitch (WebCob)
> Cc: [EMAIL PROTECTED]
> Subject: Re: [courier-users] Interection PHP with courier
>
>
>
>
> Mitch (WebCob) wrote:
>
> > Ahh - I didn't know what transport you were using.
> >
> > But from what I read in the courier / sendmail manual, the
> variables you want are
> > MAILUSER and MAILHOST --- you have an extra S - could that be the problem?
> >
> > Does that help?
>
> courier use the version with S for bounces and 'from' header ("RETURN
> ADDRESS" section) and without S for 'from' header ("SENDER ADDRESS"
> secion of man page).
> On command line it works, with php not.
>
> ciao
>       cate
>
>
>
>
>
> >
> > m/
> >
> > Giacomo A. Catenazzi ([EMAIL PROTECTED]) wrote*:
> >
> >>Mitch (WebCob) wrote:
> >>
> >>>Why do you think this would work?
> >>
> >>Hmmm. I think it should work because:
> >>1) PHP use 'sendmail' command
> >>2) courier sendmail uses the environment variables MAILSHOST and
> >>   MAILSUSER to set sender.
> >>3) The <VirtualHost *> below should set such env. vars
> >>
> >>Surely I'm wrong, but where? why?
> >>
> >>BTW: I want that my client have the right sender, but
> >>I cannot control what kind of PHP they write.
> >>
> >>ciao
> >>    cate
> >>
> >>
> >>
> >>>I've never seen any reference to this method of controlling the sender.
> >>>
> >>>I use the pear/mail classes to do this - no problems.
> >>>
> >>>m/
> >>>
> >>>Giacomo A. Catenazzi ([EMAIL PROTECTED]) wrote*:
> >>>
> >>>
> >>>>Hello.
> >>>>
> >>>>I've some problem setting the right sender in apache/PHP:
> >>>>In my apache conf I have for example:
> >>>><VirtualHost *>
> >>>>   ServerAdmin [EMAIL PROTECTED]
> >>>>   DocumentRoot /home/xxx/www.xxx.tdl
> >>>>   ServerName www.xxx.tld
> >>>>   SetEnv MAILSHOST xxx.tdl
> >>>>   SetEnv MAILSUSER info
> >>>></VirtualHost>
> >>>>
> >>>>The environment variable is set and it is correct in PHP,
> >>>>but I don't understand why PHP mail() doesn't pass it
> >>>>correctly to courier.
> >>>>
> >>>>Someone have similar problems?
> >>>>Do you have other solution on how to pass different
> >>>>sender to different virtual domains?
> >>>>
> >>>>TIA
> >>>>ciao
> >>>>  cate
> >>
> >
>



-------------------------------------------------------
The SF.Net email is sponsored by EclipseCon 2004
Premiere Conference on Open Tools Development and Integration
See the breadth of Eclipse activity. February 3-5 in Anaheim, CA.
http://www.eclipsecon.org/osdn
_______________________________________________
courier-users mailing list
[EMAIL PROTECTED]
Unsubscribe: https://lists.sourceforge.net/lists/listinfo/courier-users

Reply via email to