Mailtraq - the Complete Email Server

Enstar for Mailtraq email server sales & support
Making world-class Internet technology affordable  

Search for:

Advanced search

KB04062901 Integrate Mailtraq with PHP

Build 1670 (and above) includes support for CGI through the
web server.

Most users who have asked about CGI are particularly interested in using it
as a gateway to Perl and PHP, so I will describe the simple steps necessary
to integrate Mailtraq with PHP.

As an example, I'll explain how to install phpbb (a good quality open source
discussion forum) in Mailtraq.

1) Download the latest release of PHP (

 a) It is not necessary to run any installation scripts,
  just unzip it to a directory. 
  For this example, install to c:\php\

2) Download the latest release of phpbb (

 a) Again, it is not necessary to run any installation
  scripts, just unzip to a directory.
  For this example, install to c:\phpbb\

 b) You will need to install a suitable database
  back-end.  You can use mysql ( if
  you don't have a database installed.

3) In the Mailtraq Console, go to Options | Services and
 ensure that an HTTP Server is installed on port 80 (or
 another port if you wish)

4) Go to Options | Web Sites... and click on New Site.

5) Describe the web site as "phpbb", and associate it with
 your chosen port

6) Go to the Application tab and select
 "Standard Web Site Path" at "c:\phpbb\"

7) Go to the Documents tab and add "index.php" to the default
 documents text area on a new line.

8) Go to the Scripts tab and click "Add"

 a) Set the mask to "*.php"
 b) Select CGI
 c) Set the CGI application to c:\php\php.exe
  (if you are using PHP5, then use c:\php\php-cgi.exe

9) Close all the dialogues, and try browsing to, then go through the configuration
 process for phpbb .

Another use for CGI is to directly execute CGI applications (rather than as
a script interpreter).  To do this, simply add a scripting mask associating
"*.exe" with the command line below


(the quote marks are necessary).  It is possible to browse "through" CGI
applications, for example

in which case the cgi.exe can obtain the "/path/file" part from the
PATH_INFO environment variable (as per CGI/1.1).

Keywords: kb advanced users
Mailtraq Highlights...
 SMTP Server     Mailtraq SMTP email server video IMAP Server     Mailtraq IMAP email Server video
 POP3 Server     Mailtraq POP3 email server video Proxy Server     Mailtraq proxy email server video
 Webmail Server     Mailtraq webmail email server video Mailing-list Server     Mailing list email server video
 Groupware Services     Mailtraq groupware email services video Spam and Virus control     Spam and virus control email server video


   Copyright © 2003 - 2011 Enstar Ltd, Enstar LLC & Fastraq Ltd. All rights reserved. Privacy policy.
   Mailtraq® is a registered trademark of Fastraq Limited.