Server Configuration

Apache Version:
2.4.54  - Documentation Apache
Server Software:
Apache/2.4.54 (Win64) OpenSSL/1.1.1o PHP/7.3.21 mod_fcgid/2.3.10-dev - Port defined for Apache: 80
PHP Version:
[Apache module]  7.3.21 - Documentation PHP - Loaded PHP extensions - Use of PHP versions
[FCGI] 5.6.40 - 7.3.21 - 7.4.9 - FCGI mode help
MySQL Version:
5.7.31 - Port defined for MySQL: 3306 - default DBMS -  Documentation MySQL
MariaDB Version:
10.5.4 - Port defined for MariaDB: 3307 -  Documentation MariaDB - MySQL - MariaDB

Your Projects (10)

  • academic
  • administrative
  • apps
  • auth
  • bootstrap
  • cas
  • common
  • DonorWall
  • GCC_Logos
  • tools
  • These are your folders in c:/wamp64/www
    To use them as an http link, you must declare them as VirtualHost.
    However, you can use Right-Click, Wamp Settings, Warning: risky..., Allow links on projects...

Your Aliases (2)

Your VirtualHost (1)

PHP Loaded Extensions - Function get_loaded_extensions()
PHP 7.3.21 -> Apache module

Warning: PHP Startup: Unable to load dynamic library 'pdo_oci' (tried: c:/wamp64/bin/php/php7.3.21/ext/pdo_oci (The specified module could not be found.), c:/wamp64/bin/php/php7.3.21/ext/php_pdo_oci.dll (The specified module could not be found.)) in Unknown on line 0

 bcmath        bz2           calendar      com_dotnet    Core          ctype        
 curl          date          dom           exif          fileinfo      filter       
 gd            gettext       gmp           hash          iconv         imap         
 intl          json          ldap          libxml        mbstring      mysqli       
 mysqlnd       odbc          openssl       pcre          PDO           pdo_mysql    
 pdo_sqlite    Phar          readline      Reflection    session       SimpleXML    
 soap          sockets       SPL           sqlite3       standard      tokenizer    
 wddx          xdebug        xml           xmlreader     xmlrpc        xmlwriter    
 xsl           Zend OPcache  zip           zlib         
PHP 7.3.21 -> CLI - FCGI
 bcmath        bz2           calendar      Core          ctype         curl         
 date          dom           exif          fileinfo      filter        gd           
 gettext       gmp           hash          iconv         imap          intl         
 json          ldap          libxml        mbstring      mysqli        mysqlnd      
 openssl       pcre          PDO           pdo_mysql     pdo_sqlite    Phar         
 readline      Reflection    session       SimpleXML     soap          sockets      
 SPL           standard      tokenizer     wddx          xml           xmlreader    
 xmlrpc        xmlwriter     xsl           zip           zlib         
-- Use of PHP versions
 PHP 5.6.40  used as CLI
 PHP 7.3.21  used as APACHE module
 PHP 7.4.9   not used

How to use PHP in Fast CGI mode with Wampserver

The CGI (Common Gateway Interface) defines a way for a web server to interact with external content-generating programs, which are often referred to as CGI programs or CGI scripts. It is a simple way to put dynamic content on your web site, using whatever programming language you're most familiar with.

- Only one PHP version as Apache module

Since the beginning, Wampserver loads PHP as an Apache module:
  LoadModule php_module "${INSTALL_DIR}/bin/php/php8.1.1/php8apache2_4.dll"
which makes all VirtualHost, Alias and Projects use the same PHP version.
If you change the PHP version via the PHP menu of Wampmanager, this new version will be used everywhere.

- Several PHP versions with FCGI mode

Since Wampserver 3.2.8, it is possible to use PHP in CGI mode, i.e. you can define a different PHP version, whose addons have been previously installed, for each VirtualHost. This means that the VirtualHost are not obliged to use the same PHP version anymore.

The Apache fcgid_module ( simplifies the implementation of CGI
The documentation is here: mod_fcgid

- Prerequisites

- 1 Presence of the file in the Apache modules folder.
- 2 Presence of the module loading line in the httpd.conf file
  LoadModule fcgid_module modules/ (Not commented - No # at the beginning))
- 3 Presence of the common configuration directives of the module fcgid_module in the file httpd.conf

<IfModule fcgid_module>
  FcgidMaxProcessesPerClass 300
  FcgidConnectTimeout 10
  FcgidProcessLifeTime 1800
  FcgidMaxRequestsPerProcess 0
  FcgidMinProcessesPerClass 0
  FcgidFixPathinfo 0
  FcgidZombieScanInterval 20
  FcgidMaxRequestLen 536870912
  FcgidBusyTimeout 120
  FcgidIOTimeout 120
  FcgidTimeScore 3
  FcgidPassHeader Authorization
  Define PHPROOT ${INSTALL_DIR}/bin/php/php

These three points 1, 2 and 3 are done automatically with the Wampserver 3.2.8 update

- Creating a FCGI VirtualHost

- After the Wampserver 3.2.8 update, the 'http://localhost/add_vhost.php' page allows the addition of a FCGI VirtualHost in all simplicity.
The choice of the version of PHP to use is limited to the versions of the PHP addons installed in your Wampserver what avoids an error of version PHP.
Indeed, to declare, in a VirtualHost, a non-existent PHP version in Wampserver will generate an Apache error and a "crash" of this one.

- If you want to modify an existing VirtualHost to add the FCGI mode with an existing PHP version already in the Wampserver PHP addons, you just have to go on the page http://localhost/add_vhost.php and launch the VirtualHost modification form to be able, in three clicks, to add the FCGI mode to the VirtualHost, to change the PHP version or to remove the FCGI mode.
It will be necessary to refresh Wampserver for that to be taken into account.
This same page http://localhost/add_vhost.php also allows, via the Alias modification form, to add the FCGI mode to an Alias, to change the PHP version or to remove the FCGI mode, always in three clicks.

- Some details

To add FCGI mode to an existing VirtualHost, simply add the following directives just before the </VirtualHost> end of that VirtualHost:

  <IfModule fcgid_module>
    Define FCGIPHPVERSION "7.4.27"
    <Files ~ "\.php$">
      Options +Indexes +Includes +FollowSymLinks +MultiViews +ExecCGI
      AddHandler fcgid-script .php
      FcgidWrapper "${PHPROOT}${FCGIPHPVERSION}/php-cgi.exe" .php

The PHP version must exist as a PHP addon in your Wampserver and can be modified.
Conversely removing these lines causes the VirtualHost to revert to the PHP version used as an Apache module.

For Alias, it's a little less simple, you need to add the previous lines in two parts, the first part:

<IfModule fcgid_module>
  Define FCGIPHPVERSION "7.4.27"

just before the <Directory... directive.
The second part:

<IfModule fcgid_module>
  <Files ~ "\.php$">
    Options +Indexes +Includes +FollowSymLinks +MultiViews +ExecCGI
    AddHandler fcgid-script .php
    FcgidWrapper "${PHPROOT}${FCGIPHPVERSION}/php-cgi.exe" .php

inside the <Directory...>..</Directory> context so as to obtain, for example for any Alias, the following structure:

Alias /myalias "g:/www/mydir/"
<IfModule fcgid_module>
  Define FCGIPHPVERSION "7.4.27"
<Directory "g:/www/mydir/">
  Options Indexes FollowSymLinks
  AllowOverride all
  Require local
  <IfModule fcgid_module>
    <Files ~ "\.php$">
      Options +Indexes +Includes +FollowSymLinks +MultiViews +ExecCGI
      AddHandler fcgid-script .php
      FcgidWrapper "${PHPROOT}${FCGIPHPVERSION}/php-cgi.exe" .php

How to use MySQL and/or MariaDB?
What is a default DBMS?
How to change the default DBMS?
Go to the related help: Right-click Wampmanager icon -> Help -> MariaDB - MySQL