george goleniewski
george goleniewski

Reputation: 141

PEAR mail-queue tutorial configuration trouble

I believe that I am having problems with the .config file for the PEAR mail-queue tutorial. I have checked my paths and they are fine.

<?php

require_once "Mail/Queue.php";

$db_options['type']       = 'db';
$db_options['dsn']        = 'mysql://mysqlusername:mysqlpasswd@localhost/mail';
$db_options['mail_table'] = 'mail_queue';

$mail_options['driver']    = 'smtp';
$mail_options['host']      = 'smtp.tiscali.co.uk';
$mail_options['port']      = 25;
$mail_options['localhost'] = 'localhost'; //optional Mail_smtp parameter
$mail_options['auth']      = false;
$mail_options['username']  = 'username';
$mail_options['password']  = 'passwd';

?> 

I can independently send SMTP mail using smtp.tiscali.co.uk . I have carefully entered the table in the database mail. I added appropriate MySQL GRANT permissions. My code dies in add_message.php here but I know for a fact that the mail_queue statement is entered.

<?php
include './config.php';
/* we use the db_options and mail_options here */
$mail_queue =& new Mail_Queue($db_options, $mail_options);
/* the rest */
?>

There is a similar post by szerne on bluehostforum. http://www.bluehostforum.com/archive/index.php/t-19791.html It doesn't look too much different from mine but uses a mdb2 container. I am not sure if any details are significant. Any help would be appreciated! I am perplexed. Many thanks, George

Upvotes: 3

Views: 1065

Answers (1)

george goleniewski
george goleniewski

Reputation: 141

Use MDB2.

Failure to install MDB2 and its mysql options. Not explicitly mentioned in PEAR mail-queue tutorial.

Works well now.

Upvotes: 1

Related Questions