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:


require_once "Mail.php";

$host = "ssl://";
$port = "587";
$username = "";
$password = "Password";
$from = "King Coffee <>";
$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( "<p>" . $mail->getMessage() . "</p>");
} else {
        echo("<p>Message successfully sent</p>");


<title>PHP EMAIL TESTER</title>
<h1>This is a test</h1>
<?php Echo "Hi King"; ?>

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?


PHP General Mailing List (
To unsubscribe, visit:

Reply via email to