Mantis related Configuration

Source: Internet
Author: User

Mantis Platform Windows Configuration Manual (http://www.mantisbt.org/)

Software that needs downloading
Download Xampp-win32-1.6.1.exe (Windows) integrated PHP, Apache, MYSQL, to meet the Mantis platform for PHP platform, server, database requirements.
Mantis-1.1.0a4.tar.gz
Second, the Xampp-win32-1.6.1.exe software installation here will not say.
Unzip the mantis-1.1.0a4.tar.gz installation file
Execute admin/install.php
Unimpeded.

Third, the mantis platform of Chinese:
Modify the config_defaults_inc.php file in the Mantis directory below $g _default_language = ' 中文版 '; $g _default_language = ' Chinese_simplified_utf8 ';
Add $g _default_language = ' Chinese_simplified_utf8 ' in config_inc.php;
Han-ok.

This software has a variety of language options, you can choose the Chinese version. Myaccount-->preferences-->language.

1. Chinese code set

To : Resolve the Chinese font garbled problem when browser accesses Mantis

Modify the default profile config_defaults_inc.php in Mantis, and find the following to control the changes.

If you copy the following content to config_inc.php, you can also.

Configuration file load order: Load config_defaults_inc.php First, then load config_inc.php.

The value in the config_inc.php overrides config_defaults_inc.php.

################################
# Mantis Language Settings
################################

#---language Settings-----------
# If The language is set to ' auto ', the actual
# language is determined by the user agent (Web browser)
# language Preference.
$g _default_language = ' chinese_simplified_gb2312 ';

# list the choices that's the users are allowed to choose
$g _language_choices_arr = Array (
' Auto ',
' Bulgarian ',
' Catalan ',
' chinese_simplified_gb2312 ',
' Chinese_traditional ',
' Croatian ',
' Czech ',
' Danish ',
' Dutch ',
' 中文版 ',
' Estonian ',
' Finnish ',
' French ',
' German ',
' Hebrew ',
' Hungarian ',
' Icelandic ',
' Italian ',
' Japanese ',
' Korean ',
' Latvian ',
' Lithuanian ',
' Norwegian ',
' Polish ',
' Portuguese_brazil ',
' Portuguese_standard ',
' Romanian ',
' Russian ',
' Serbian ',
' Slovak ',
' Slovene ',
' Spanish ',
' Swedish ',
' Turkish ',
' Ukrainian '
);

# Browser language mapping for ' auto ' language selection
$g _language_auto_map = Array (
' BG ' => ' Bulgarian ',
' Ca ' => ' Catalan ',
' Zh-cn, ZH-SG, zh ' => ' chinese_simplified_gb2312 ',
' Zh-hk, zh-tw ' => ' chinese_traditional ',
' CS ' => ' Czech ',
' da ' => ' Danish ',
' Nl-be, nl ' => ' Dutch ',
' En-us, EN-GB, En-au, en ' => ' 中文版 ',
' et ' => ' Estonian ',
' fi ' => ' Finnish ',
' Fr-ca, fr-be, Fr-ch, Fr ' => ' French ',
' De-de, De-at, De-ch, de ' => ' German ',
' He ' => ' Hebrew ',
' Hu ' => ' Hungarian ',
' HR ' => ' Croatian ',
' Is ' => ' Icelandic ',
' It-ch, it ' => ' Italian ',
' ja ' => ' Japanese ',
' ko ' => ' Korean ',
' Lt ' => ' Lithuanian ',
' LV ' => ' Latvian ',
' No ' => ' Norwegian ',
' PL ' => ' polish ',
' Pt-br ' => ' Portugese_brazil ',
' PT ' => ' Portugese_standard ',
' Ro-mo, ro ' => ' Romanian ',
' Ru-mo, Ru-ru, Ru-ua, Ru ' => ' Russian ',
' SR ' => ' Serbian ',
' SK ' => ' Slovak ',
' SL ' => ' Slovene ',
' Es-mx, Es-co, Es-ar, ES-CL, es-pr, es ' => ' Spanish ',
' Sv-fi, SV ' => ' Swedish ',
' TR ' => ' Turkish ',
' UK ' => ' Ukrainian '
);

# Fallback for automatic language selection
$g _fallback_language = ' 中文版 ';

2. Mail Configuration

To : Troubleshoot mail delivery issues

The following content can be found in config_defaults_inc.php.

It is recommended that the content be handcuffed to the config_inc.php.

#############################
# Mantis Email Settings
#############################

#---Email variables-------------
$g _administrator_email = ' testsrv@xxx.com ';
$g _webmaster_email = ' testsrv@xxx.com ';

# the ' From: ' field in emails
$g _from_email = ' testsrv@xxx.com ';

# The return address for bounced mail
$g _return_path_email = ' testsrv@xxx.com ';

# Allow email notification
# The IF is disabled, sign-up and password reset messages would
# not to be sent.
$g _enable_email_notification = on;
# Select the method to mail by:
# 0-mail ()
# 1-sendmail
# 2-SMTP
$g _phpmailer_method = 2;

# This option allows a remote SMTP host. Must use the Phpmailer scrīpt
# Name of SMTP host, needed for Phpmailer, taken from php.ini
$g _smtp_host = ' mail.xxx.com ';

# These options allow the use of SMTP authentication when your use a remote
# SMTP host with Phpmailer. If Smtp_username is not ' then the username
# and password'll be used when logging into the SMTP server.
$g _smtp_username = ' testsrv ';
$g _smtp_password = ' testsrv ';

The configuration of the messaging system is recommended by SMTP. The general company has its own mail server, let the administrator to open a Mantis special mailbox for you.

Another: I configure the Mantis mail service, there have been a successful message sent but not received, and then let the company administrator assistance, from the mail server background log check. The original is the testsrv@xxx.com written testesrv@xxx.com.

Oh, be careful.

Experience.

3. Graphic Report

To : Solve the graphics report in Chinese font output problem.

In mantis1.1, it's a little bit simpler now, just change the font.

Open the core/graph_api.php file, find the following, and add a row:

function Graph_get_font () {
$t _font_map = Array (
' SimSun ' => Ff_simsun,
' Arial ' => ff_arial,
' Verdana ' => Ff_verdana,
' Courier ' => Ff_courier,
' Comic ' => ff_comic,
' Times ' => ff_times,
' Georgia ' => Ff_georgia,
' Trebuche ' => ff_trebuche,
' Vera ' => Ff_vera,
' Veramono ' => Ff_veramono,
' Veraserif ' => ff_veraserif);

$t _font = config_get (' Graph_font ', ');
if (Isset ($t _font_map[$t _font])) {
return $t _font_map[$t _font];
} else {
return ff_font1;
}

Also note that config_inc.php or config_defaults_inc.php should have the following configuration content:

############################
# Mantis Jpgraph Addon
############################

#---jpgraph Settings---#
# Initial Version from Duncan lisset
#
# to use the Jpgraph addon your need the Jpgraph package from
# http://www.aditus.nu/jpgraph/index.php
# You can place the package whereever your want, but you have
# to set the Var in jpgraph.php eg.
# (DEFINE (' dir_base ', '/www/mantisbt/jpgraph/');)

$g _use_jpgraph = on;
$g _jpgraph_path = ' d:/mantis-1.1.0a2/core/jpgraph/src '. Directory_separator. '' .   Directory_separator; # dont forget the ending slash!

#注意: Here you need to specify the path to the src/jpgraph.php. There is a hint when the page goes wrong.

# What TrueType font'll the graphs use. Allowed values are ' Arial ', ' Verdana ', ' Courier ', ' book ', ' Comic ', ' The Times ',
# ' Georgia ', ' Trebuche ', ' Vera ', ' Veramono ', or ' veraserif '. Refer to the Jpgraph manual for details.
# Note:these fonts need to is installed in the Ttf_dir as specified to Jpgraph
$g _graph_font = ' SimSun ';

# What width is used to scale the graphs.
$g _graph_window_width = 800;
# Bar graph aspect ration (height/width)
$g _graph_bar_aspect = 0.9;

# How many graphs into put in each row in the Advanced summary page
$g _graph_summary_graphs_per_row = 2;

$g _system_font_folder = ' c:/winnt/fonts/';

$g _font_per_captcha = ' Simsun.ttf ';

4. Time zone settings

To: Resolve Mantis page Time display problem, the default is GMT Greenwich Mean time. 8 hours apart from China.

Add the following in config_inc.php or config_defaults_inc.php:

#时区设置

Putenv ("Tz=asia/shanghai");

In addition, some people on the Internet also mentioned the following settings in PHP.ini. (If the PUTENV function does not work, you can try it)

[Date]
; Defines the default timezone used by the date functions
Date.timezone = Asia/shanghai

5. Database (Mysql)

Version: MySQL 5.0 Series

Many people use phpMyAdmin to manage MySQL data.

Suggest everybody use mysql-front, I use is 3.2 edition.

Graphical interface is very convenient to operate.

The data source connection configuration in mantis is relatively simple and is set in config_inc.php:

################################
# Mantis Database Settings
################################

#---database variables---------

# set these values to match your setup

# hostname should is either a hostname or connection string to supply to ADODB.
# For example, if your would like to connect to a MySQL server in the local machine,
# set hostname to ' localhost ', and db_type to ' MySQL '.
# If you are need to supply a port to connect to, set hostname as ' localhost:3306 '.
$g _hostname = ' localhost ';
$g _db_username = ' mantis ';
$g _db_password = ' mantis ';
$g _database_name = ' mantis ';

#这里 The database username, password, and database name are all used mantis.

#要在myssql中新建一个数据库用户mantis, pay attention to it enough permissions.

# supported Types:mysql for MySQL, mysqli for MySQL, pgsql for PostgreSQL, MSSQL for MS SQL Server, oci8 for Oracle. There are a lot of database types supported here.
$g _db_type = ' MySQL ';

6.web Server (Apache Or IIS)

Mantis is currently used in these two types of services, here is recommended with Apache.

The Apache version is now 2.2 series. Configuration is primarily a configuration of the application services directory,

Open apache/conf/httpd.conf and add the following at the end of the file:

Alias/mantis "d:/mantis-1.1.0a2/"
#这是服务访问的虚拟路径设置

<directory "d:/mantis-1.1.0a2/" >
Options Indexes
AllowOverride None
Order Allow,deny
Allow from all
</Directory>

Apache Port Modifications:

#Listen 12.34.56.78:80
Listen 80

Default application directory modifications:

DocumentRoot "D:/MANTIS-1.1.0A2"

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.