Ive found this nifty script that does what I want - in PEAR.. (to send emails)
However i'm getting an error.. - Can anyone advise a suitable course of action to correct this :- Code: <?php require_once "Mail.php"; /************************************************** EDIT the following variables for your own use ***************************************************/ $from = "Sender <[EMAIL PROTECTED]>"; $to = "[EMAIL PROTECTED]"; $subject = "Hi!"; //type in subject here $host = "MYHOST"; // Your domain $username = "USER"; // Your user / full email address $password = "PASSWORD"; // Password to your email address echo " <PRE> Using NEW password server / Userid. - JAN 27th 2007 \n\n"; /************************************************** ***************************************************/ $body = " Hi"; foreach($_POST as $a => $b) { $body .= $a .": ". $b . "\n"; } $headers = array ('From' => $from, 'To' => $to, 'Subject' => $subject); $smtp = Mail::factory('smtp', array ('host' => $host, 'auth' => true, 'username' => $username, 'password' => $password)); $mail = $smtp->send($to, $headers, $body); if (PEAR::isError($mail)) { /************************************************** ERROR MESSAGE ***************************************************/ ?> <p> <? echo $mail->getMessage(); ?> </p> <? /**************************************************/ } else { /************************************************** SUCCESS MESSAGE ***************************************************/ ?> <p>Message successfully sent!</p> <? /**************************************************/ } ?> (the host is NOT on powweb - & the username etc are correct) The error message is :- Quote: Fatal error: main() [function.require]: Failed opening required 'Mail.php' (include_path='.:/usr/local/lib/php') in /hermes/web09/ etc... Does the error message mean I need to find the exact pathname for the PEAR files ? (everyone on my ISP seems to be asleep - I sent the above message yestrerday to the forum. .(apartt from the immediate question above...) -- G NZ community groups - [EMAIL PROTECTED] Freecycle Auckland :- http://groups.yahoo.com/group/AucklandFreecycle/