How to install PhpWiki on a CentOS 7 VPS

PhpWiki is a wiki-based content management software written in PHP, used to create web sites where anyone can edit or create the pages using a web browser.
In this tutorial we will show you the steps needed to install PhpWiki on a CentOS 7 VPS.

At the time of writing this tutorial, the latest stable version of PhpWiki is 1.5.3 and it requires:

PHP 5.3.29 or higher, compiled with support for the type of database you want to use and with the PEAR libraries enabled;

Apache Web Server 2.0 or higher compiled with mod_rewrite module;

MySQL, MariaDB, PostgreSQL or SQLite.

This install guide assumes that Apache, MySQL (or MariaDB) and PHP are already installed and configured on your virtual server. If your server has a minimal CentOS 7 base installation, you can install Apache, MariaDB and PHP stack by following this tutorial.

Download the latest version of PhpWiki available at ‘http://downloads.sourceforge.net/project/phpwiki/’ to the server and extract it using the following commands:

Copy ‘/var/www/html/config/config-dist.ini’ to ‘/var/www/html/phpwiki/config/config.ini’ and edit the settings in ‘/var/www/html/phpwiki/config/config.ini’ file according to your needs. It may be simpler for you to use http://phpwiki.fr/configurator.php to generate the ‘config.ini’ configuration file for PhpWiki:

enter the name of your website, administrator username and password

make sure you select to use encrypted passwords to be stored in the ‘config.ini’ file and the users homepages metadata

set the path to access log file (e.g. /var/log/httpd/yourdomain.com-access_log)

set ‘COMPRESS_OUTPUT’ to true (Always try to compress output)

set ‘HTTP Cache Control’ to ‘LOOSE’ so cached pages will be invalidated whenever they are edited

edit part four: ‘Page appearance and layout’ according to your liking and finally click on the ‘Save config/config.ini’ button.

Copy the generated configuration to a file, and save it as ‘/var/www/html/phpwiki/config/config.ini’. Set the proper ownership of PhpWiki files and directories using the following command:

chown apache:apache -R /var/www/html/phpwiki/

That is it. The PhpWiki installation is now complete.

Open http://yourdomain.com in your favorite browser and once the initialization complete, open http://yourdomain.com/index.php/PhpWikiAdministration and log in using your Administrator login credentials.
Of course you don’t have to do any of this if you use one of our Linux VPS Hosting services, in which case you can simply ask our expert Linux admins to install PhpWiki for you. They are available 24×7 and will take care of your request immediately.

PS. If you liked this post please share it with your friends on the social networks using the buttons on the left or simply leave a reply below. Thanks.