Download & Extend

SMTP Wrapper Support - class.smtp.inc not available any longer

Project:Mail
Version:4.6.x-1.x-dev
Component:Miscellaneous
Category:support request
Priority:normal
Assigned:Unassigned
Status:postponed (maintainer needs more info)

Issue Summary

Hello - sorry to post this as an issue if it doesn't qualify. However, I can not find a solution for setting up an external SMTP server for mail functions. The only solution that seems to work is using smtp.inc and class.smtp.inc - however, class.smtp.inc is unavailable (the host site for the file, phpguru.org has been down for days). Is it possible to attach the class.smtp.inc file somewhere in the Drupal site for people to use?

Comments

#1

If anyone out there is using an external smtp server and has the class.smtp.inc file that they downloaded from phpguru.org - please contact me! http://drupal.org/user/28950/contact

#2

I found the file and installed and tested it, using Civicspace 0.8.1.2.

File is attached.

AttachmentSize
class.smtp.inc 9.76 KB

#3

And here are some detailed instructions... this solution should
enable you to also modify the smtp.inc to specify a username
and login for your external SMTP server!

THE FIX:

I noticed we were getting errors from our installation of
Civicspace on Dreamhost. The problem was that some
recipients were not receiving mail from us as a result of spam
filtering.

The fix for this was to modify Drupal settings, by installing
some custom SMTP code and then changing the settings for
our mail server, so that Drupal would use mail.ourserver.org
(instead of the default, which turned out to be 'localhost'
(or tetris.dreamhost.org).

1) download the following 2 files and place in Includes:

http://cvs.drupal.org/viewcvs/*checkout*/drupal/contributions/tricks/smt...
http://www.lemure.net/~chuck/openbsd_help/class.smtp.inc

2) Edit smtp.inc so that the default smtp server address is no longer used:

before: $params['host'] = ini_get('SMTP');
after: $params['host'] = "mail.ourserver.org";

3) make Drupal use this mail sending wrapper by adding the following line at the end
of conf.php, before the last ?> tag:

$conf["smtp_library"] = "includes/smtp.inc";

Hope this helps.

-rich

#4

fyi, the two lines in smtp.inc that you want to modify, in order to set up smtp authentication, look like this:

// Username for authentication
//$params['user'] = 'testuser';
// Password for authentication
//$params['pass'] = 'testuser';

-rich

#5

Status:active» closed (fixed)

Closed..

#6

Status:closed (fixed)» postponed (maintainer needs more info)

What is recommended for the latest versions of PHP and Drupal?

nobody click here