Question

I have matisbt 1.2.12 deployed in XAMPP . I am not able to configure the email(Microsoft Exachnage server ). My config_inc look like this:

    <?php
         $g_hostname = 'localhost';
         $g_db_type = 'mysql';
         $g_database_name = 'bugtracker';
         $g_db_username = 'root';
         $g_db_password = 'XXXXXX';
         #Branding Mantis
         #Display
         $g_window_title = 'XXXXX';
         $g_favicon_image='images/XXXX';
         $g_logo_url = 'http://XXXX';
         $g_logo_image = 'images/XXXXX'; 
         #SMTP Config
         $g_log_level = LOG_EMAIL | LOG_EMAIL_RECIPIENT;
         $g_log_destination = 'file:D:/Bug_tracker/xampp/apache/logs/mantisbt.log';
         $g_allow_signup    = ON;  //allows the users to sign up for a new account
         $g_enable_email_notification = ON; //enables the email messages
         $g_phpMailer_method = PHPMAILER_METHOD_SMTP;
         $g_smtp_host = 'XXXXX';
         $g_smtp_connection_mode = 'tls';
         $g_smtp_port = '25';
         $g_smtp_username = 'XXXXXXX';
         $g_smtp_password = 'XXXXXX';
         $g_from_email = 'XX@XXXX';
         $g_administrator_email = 'XXXXXXXX'; 
         $g_from_name         = 'XXX Bug Tracker';
     ?>

The host is the ip address of exchange server. The log files at $g_log_destination gives

Password reset for email = User email id here
2013-03-07 13:31 EST mail Processing 27 queued messages
2013-03-07 13:31 EST mail Sending message #52 queued on 2013-03-07 13:31 EST
2013-03-07 13:31 EST mail Sending message #51 queued on 2013-03-07 13:20 EST
2013-03-07 13:31 EST mail Sending message #50 queued on 2013-03-07 13:13 EST
2013-03-07 13:31 EST mail Sending message #49 queued on 2013-03-07 13:04 EST
2013-03-07 13:31 EST mail Sending message #48 queued on 2013-03-07 12:53 EST

I tried $g_smtp_connection_mode = 'ssl' also. When i put PHPMAILER_METHOD_SMTP inside single quotes. The email content is generated in the folder xampp\tmp\mailoutput

I have download the testmail.php from http://www.mantisbt.org/forums/viewtopic.php?f=3&t=15398. It works fine.

Was it helpful?

Solution

Try configuring the following set of lines to put in your config_inc.php

# --- Database Configuration ---
$g_hostname      = 'hostname.com';
$g_db_username   = 'username';
$g_db_password   = 'password';
$g_database_name = 'dbname';
$g_db_type       = 'mysql';

# --- Anonymous Access / Signup ---
$g_allow_signup             = ON;
$g_allow_anonymous_login    = OFF;
$g_anonymous_account        = '';

# --- Email Configuration ---
$g_phpMailer_method     = PHPMAILER_METHOD_MAIL; # or PHPMAILER_METHOD_SMTP, PHPMAILER_METHOD_SENDMAIL
$g_smtp_host            = 'hostname.com';# used with PHPMAILER_METHOD_SMTP
$g_smtp_username        = '';                   # used with PHPMAILER_METHOD_SMTP
$g_smtp_password        = '';                   # used with PHPMAILER_METHOD_SMTP
$g_administrator_email  = 'anymailid@gmail.com';
$g_webmaster_email      = 'webmaster@gmail.com';
$g_from_name            = 'Gecko Bug Tracker';
$g_from_email           = 'anymailid@gmail.com';    # the "From: " field in emails
$g_return_path_email    = 'anymailid@gmail.com';    # the return address for bounced mail
$g_email_receive_own    = OFF;
$g_email_send_using_cronjob = OFF;

# --- Attachments / File Uploads ---
$g_allow_file_upload    = ON;
$g_file_upload_method   = DATABASE; # or DISK
$g_absolute_path_default_upload_folder = ''; # used with DISK, must contain trailing \ or /.
$g_max_file_size        = 5000000;  # in bytes
$g_preview_attachments_inline_max_size = 256 * 1024;
$g_allowed_files        = '';       # extensions comma separated, e.g. 'php,html,java,exe,pl'
$g_disallowed_files     = '';       # extensions comma separated

# --- Branding ---
$g_window_title         = 'Gecko';
$g_logo_image           = 'images/mantis_logo.gif';
$g_favicon_image        = 'images/favicon.ico';

# --- Real names ---
$g_show_realname = OFF;
$g_show_user_realname_threshold = NOBODY;   # Set to access level (e.g. VIEWER, REPORTER, DEVELOPER, MANAGER, etc)

# --- Others ---
$g_default_home_page = 'my_view_page.php';  # Set to name of page to go to after login


$g_enable_profiles = OFF;
$g_allow_no_category = ON;

$g_set_bug_sticky_threshold = NOBODY;
$g_move_bug_threshold = NOBODY;
$g_set_bug_sticky_threshold = NOBODY;`
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top