Calling PHP gurus

This is a discussion on Calling PHP gurus within the PHP Language forums, part of the PHP Programming Forums category; It's nice to see all the support in this newsgroup. Hopefully I'll be a contributor soon. For now ...


Go Back   Usenet Forums > PHP Programming Forums > PHP Language

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 03-07-2004
Lochness
 
Posts: n/a
Default Calling PHP gurus

It's nice to see all the support in this newsgroup. Hopefully I'll be a
contributor soon.

For now I'm hoping you could answer a question about the mail function in
PHP. When I use the mail command in my localhost, it's great. I can modify
the headers, use html tags, etc. But when I use it on my web space (1and1),
the header comes back as cgi-mailer-bounces-...@perfora.net, the header info
I entered, shows in the message (instead of the header) and the html tags
are displayed in the message as regular text.

Of course the php.ini file on my webspace is read only, so is there any php
commands I can use to override the display of the header and the use html
tags?

Any help would be greatly appreciated. Thanks and have a great day!


Reply With Quote
  #2 (permalink)  
Old 03-07-2004
Mangina
 
Posts: n/a
Default Re: Calling PHP gurus

The only way I've EVER been able to get mail working 100% of the time (i.e.
not bounced,
not blocked, thru spam filters, etc.) is the use PHPMailer
(http://phpmailer.sourceforge.net/).

"Lochness" <someone@somewhere.com> wrote in message
news:7Ps2c.726385$ts4.121656@pd7tw3no...
> It's nice to see all the support in this newsgroup. Hopefully I'll be a
> contributor soon.
>
> For now I'm hoping you could answer a question about the mail function in
> PHP. When I use the mail command in my localhost, it's great. I can

modify
> the headers, use html tags, etc. But when I use it on my web space

(1and1),
> the header comes back as cgi-mailer-bounces-...@perfora.net, the header

info
> I entered, shows in the message (instead of the header) and the html tags
> are displayed in the message as regular text.
>
> Of course the php.ini file on my webspace is read only, so is there any

php
> commands I can use to override the display of the header and the use html
> tags?
>
> Any help would be greatly appreciated. Thanks and have a great day!
>
>



Reply With Quote
  #3 (permalink)  
Old 03-07-2004
Hayden Kirk
 
Posts: n/a
Default Re: Calling PHP gurus

They dont support html email...


"Lochness" <someone@somewhere.com> wrote in message
news:7Ps2c.726385$ts4.121656@pd7tw3no...
> It's nice to see all the support in this newsgroup. Hopefully I'll be a
> contributor soon.
>
> For now I'm hoping you could answer a question about the mail function in
> PHP. When I use the mail command in my localhost, it's great. I can

modify
> the headers, use html tags, etc. But when I use it on my web space

(1and1),
> the header comes back as cgi-mailer-bounces-...@perfora.net, the header

info
> I entered, shows in the message (instead of the header) and the html tags
> are displayed in the message as regular text.
>
> Of course the php.ini file on my webspace is read only, so is there any

php
> commands I can use to override the display of the header and the use html
> tags?
>
> Any help would be greatly appreciated. Thanks and have a great day!
>
>



Reply With Quote
  #4 (permalink)  
Old 03-07-2004
Manuel Lemos
 
Posts: n/a
Default Re: Calling PHP gurus

Hello,

On 03/06/2004 08:05 PM, Lochness wrote:
> It's nice to see all the support in this newsgroup. Hopefully I'll be a
> contributor soon.
>
> For now I'm hoping you could answer a question about the mail function in
> PHP. When I use the mail command in my localhost, it's great. I can modify
> the headers, use html tags, etc. But when I use it on my web space (1and1),
> the header comes back as cgi-mailer-bounces-...@perfora.net, the header info
> I entered, shows in the message (instead of the header) and the html tags
> are displayed in the message as regular text.
>
> Of course the php.ini file on my webspace is read only, so is there any php
> commands I can use to override the display of the header and the use html
> tags?


If they are using safe mode probably not.

Anyway, you may want to try this class that lets you specify the
return-path address as a (virtual) header of your mail messages.

It comes with several sub-classes to let you try different delivery
modes (mail() function, sendmail program, qmail program and smtp TCP
connection.) Depending on what your ISP blocked, you may want to try one
each of the sub-classes until one works.

To simplify your task, the class comes with several wrapper functions
named sendmail_mail(), qmail_mail() and smtp_mail(), each using one of
the sub classes, that emulate the mail() function, so you do not have to
change your scripts much.

http://www.phpclasses.org/mimemessage


--

Regards,
Manuel Lemos

PHP Classes - Free ready to use OOP components written in PHP
http://www.phpclasses.org/

PHP Reviews - Reviews of PHP books and other products
http://www.phpclasses.org/reviews/

Metastorage - Data object relational mapping layer generator
http://www.meta-language.net/metastorage.html
Reply With Quote
  #5 (permalink)  
Old 03-07-2004
Lochness
 
Posts: n/a
Default Re: Calling PHP gurus

Woohoo it worked awesome! And I only need to include two class files.

Thank you so much Mangina!!

"Mangina" <support@microsoft.com> wrote in message
news:104kmicgbi8vca0@corp.supernews.com...
> The only way I've EVER been able to get mail working 100% of the time

(i.e.
> not bounced,
> not blocked, thru spam filters, etc.) is the use PHPMailer
> (http://phpmailer.sourceforge.net/).
>
> "Lochness" <someone@somewhere.com> wrote in message
> news:7Ps2c.726385$ts4.121656@pd7tw3no...
> > It's nice to see all the support in this newsgroup. Hopefully I'll be a
> > contributor soon.
> >
> > For now I'm hoping you could answer a question about the mail function

in
> > PHP. When I use the mail command in my localhost, it's great. I can

> modify
> > the headers, use html tags, etc. But when I use it on my web space

> (1and1),
> > the header comes back as cgi-mailer-bounces-...@perfora.net, the header

> info
> > I entered, shows in the message (instead of the header) and the html

tags
> > are displayed in the message as regular text.
> >
> > Of course the php.ini file on my webspace is read only, so is there any

> php
> > commands I can use to override the display of the header and the use

html
> > tags?
> >
> > Any help would be greatly appreciated. Thanks and have a great day!
> >
> >

>
>



Reply With Quote
  #6 (permalink)  
Old 03-07-2004
gmuldoon
 
Posts: n/a
Default Re: Calling PHP gurus

someone@somewhere.com says...

> For now I'm hoping you could answer a question about the mail function in
> PHP. When I use the mail command in my localhost, it's great. I can modify
> the headers, use html tags, etc. But when I use it on my web space (1and1),
> the header comes back as cgi-mailer-bounces-...@perfora.net, the header info
> I entered, shows in the message (instead of the header)


Email "from" and "reply-to" values set in the "header" section are
probably being over-written by security setting in mail on the server.
Not unusual. Try setting these using the fifth parameter of the mail
function instead (-f for from, reply-to). The PHP install account will
need to be "trusted" by your mail program. Eg:

$to="you@there.com";
$subject="The subject";
$headers="";
$body="The message.";
$params="-f me@here.com";

mail($to, $subject, $body, $headers, $params);

Geoff M
Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT +1. The time now is 07:14 AM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0