Re: [PHP] PHP SMTP Mailers

2010-03-22 Thread King Coffee

Thanks,

I try it and had not problems!

King 


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



Re: [PHP] PHP SMTP Mailers

2010-03-22 Thread Michael A. Peters

King Coffee wrote:

Hi,

I'm executing a third-parity standard PHP application on a Windows IIS 7 
shared hosting server.


I need to convert, or use, a SMTP mailer service.  I found two SMTP PHP 
scripts - I think may work.


The sourceforge.net PHPMailer project and the pear.php.net (Mail, 
Net_SMTP) project.


Can any body please help me choose one and probably give a code snip of 
useage?


Currently, I'm leaning forward the PHPMailer, with little to base the 
decision on.


Thanks in advanced,
King Coffee



I use phpmailer and find it to be painless and consistent.

I extend the class and call the extended class:



Then when I want to use it -

$mail = new MyMailer();
$mail->Subject  = "Some Subject";
$mail->Body = "Some content";
if($mail->Send()) {
   // it was successfully sent, code on success here
   } else {
   // there was an error, error code here
   }

I never send HTML mail or attachments or bulk mail, but I believe it is 
capable of doing them quite easily.


Tip: Whatever solution you use, set the wordwrap to something that works 
well on an 80 char display. Some clients do not autowrap unwrapped 
messages and other clients wrap for display but when replying, it 
doesn't wrap.


I use 75 because it gives a little room for the "> " that accompanies a 
reply.


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



Re: [PHP] PHP SMTP Mailers

2010-03-21 Thread King Coffee

Thanks Jan G. B., You got me over the first hump.

I'm having programs installing pear on my VISTA localhost...
So, I uploaded the Mail folder and Mail.php file to my
Shared Hosting ISP. I do not think pear is provided.

The Testing is as follows:

";
$to = "Bill ";
$subject = "PHP Mail Test";
$body = "This is a simple mail test!";

$headers = array('From' => $from,
'To' => $to,
'Subject' => $subject);

$smtp = Mail::factory('smtp',
array('host' => $host,
'port' => $port,
'auth' => true,
'username' => $username,
'password' => $password));

$mail = $smtp->send($to, $header, $body);

if(PEAR::isError($mail)) {
echo( "" . $mail->getMessage() . "");
} else {
echo("Message successfully sent");
}

?>



PHP EMAIL TESTER
This is a test




When I run the server page, The following error is displayed:

Warning: require_once(PEAR.php) [function.require-once]: failed to open 
stream: No such file or directory in D:\Hosting\ID#\html\auction\Mail.php on 
line 46


Fatal error: require_once() [function.require]: Failed opening required 
'PEAR.php' (include_path='.;C:\php5\pear') in 
D:\Hosting\ID#\html\auction\Mail.php on line 46


I will be still trying the get pear installed in VISA, but meanwhile, how 
can I obtain the PEAR.php and supporting files to upload?


Thanks,
King 



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



Re: [PHP] PHP SMTP Mailers

2010-03-20 Thread Jan G.B.
2010/3/20 King Coffee 

> Hi,
>
> I'm executing a third-parity standard PHP application on a Windows IIS 7
> shared hosting server.
>
> I need to convert, or use, a SMTP mailer service.  I found two SMTP PHP
> scripts - I think may work.
>
> The sourceforge.net PHPMailer project and the pear.php.net (Mail,
> Net_SMTP) project.
>
> Can any body please help me choose one and probably give a code snip of
> useage?
>
> Currently, I'm leaning forward the PHPMailer, with little to base the
> decision on.
>
> Thanks in advanced,
> King Coffee


Hi. I'd stick to a PEAR module as long as it exists, because you can update
it easily.

Check out the examples in the PEAR Documentation.
http://pear.php.net/manual/en/package.mail.mail.intro.php

There's also a full detail example here:
http://pear.php.net/manual/en/package.mail.mail.send.php

Bye


[PHP] PHP SMTP Mailers

2010-03-20 Thread King Coffee

Hi,

I'm executing a third-parity standard PHP application on a Windows IIS 7 
shared hosting server.


I need to convert, or use, a SMTP mailer service.  I found two SMTP PHP 
scripts - I think may work.


The sourceforge.net PHPMailer project and the pear.php.net (Mail, Net_SMTP) 
project.


Can any body please help me choose one and probably give a code snip of 
useage?


Currently, I'm leaning forward the PHPMailer, with little to base the 
decision on.


Thanks in advanced,
King Coffee 



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