Closed (fixed)
Project:
SMTP Authentication Support
Version:
8.x-1.0-beta6
Component:
Miscellaneous
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
7 Jan 2020 at 14:22 UTC
Updated:
23 Jan 2026 at 00:04 UTC
Jump to comment: Most recent
Comments
Comment #2
bluegeek9 commentedThe SMTP module intercepts PHPMailer's debug output and redirects it to Drupal's logging system instead of echoing to the browser.
1. Lines 260-267: When debugging is enabled, the module sets a custom `Debugoutput` callback that stores debug messages in the session:
260:267:src/Plugin/Mail/SMTPMailSystem.php
2. Lines 961-976: The `debug()` method (called after sending email) retrieves these messages and logs them via Drupal's logger:
961:976:src/Plugin/Mail/SMTPMailSystem.php
Where to Find the Debug Information
The debug messages are logged to Drupal's database log (watchdog), not echoed to the browser. To view them:
1. Go to `/admin/reports/dblog` (Recent log messages)
2. Filter by the "smtp" channel or severity "Debug"
3. Look for entries with the debug messages
The `do_debug` variable you're seeing is from PHPMailer's internal SMTP class. The module overrides PHPMailer's default `echo` behavior and routes output to Drupal's logging system.
If you need browser output, you'd need to modify the `Debugoutput` callback to echo directly, but that can break AJAX/batch operations, which is why the module uses logging instead.
Comment #4
bluegeek9 commentedComment #6
bluegeek9 commented