Recently, I've been busy preparing various directories for additional archiving in Linux (it's about files from the /var/log/ location) containing archives of reports of performed operations in the system and running programs (services such as www etc.). Since I often use archiving to RAR format, I decided to see if it would work in this case as well.
I wrote a script that installs Nextcloud package (an alternative to other disk services in the so-called cloud), in Debian 11 (Linux). To work it requires only a clean system, everything will install and configure itself (so that it works on the local network, the operation outside must be configured by the user).
A new script for CentOS 8 was introduced in the projects, which is used to install and configure additional software and system to allow serving the website.
The script installs and pre-configures things like web server, database server, PHP interpreter.
Today's entry concerns the launch of statistics of website visits based on the WordPress system, using the BBClone – a script entitled as – A PHP based Web Counter on Steroids!
There's not much to describe, so I'll get to the point. I assume you already have a working WordPress engine site.
1 – We are downloading a development version of the BBClone (the last stable release is from 2015, and does not support PHP version 7, so we need a version with later changes). Link to file: http://download.bbclone.org/bbclone-nightly-build.zip. 2 – The unpacked files are copied via FTP to a server. We can rename the bbclone directory to another. 3 – Edit the config.php file from the /conf/ directory, where you set the parameters as required. 4 – We change the WordPress file, template-loader.php, which is located in the /wp-includes/ directory. Simply add this piece of code under the first line containing "<?php":
Instead of /home/user/public_html/bbbclone/ (bold above) you should enter your own full bbclone directory location on the server. Upload the modified file, replacing the original and it's ready.
The only thing you need to remember is to correct this file after updating WordPress.