You have a folder public on the server /var/www/site.com/public/ And want to check its permissions without accessing the terminal, using PHP. To do this, run the following command. $folder = '/var/www/site.com/public/'; echo 'Permissions: ' . substr(sprintf('%o', fileperms($folder)), -3); echo 'Owner: ' . posix_getpwuid(fileowner($folder))['name']; echo 'Group: ' . posix_getgrgid(filegroup($folder))['name']; The result...
Month: December 2025
UFW is a convenient wrapper around iptables. 1. Checking and installing UFW sudo apt update sudo apt install ufw -y Examination: ufw status Most likely: Status: inactive. This is normal. 2. You must allow SSH (otherwise you'll crash!) sudo ufw allow OpenSSH 3. Allow the required services For web server: sudo ufw allow 80/tcp # HTTP sudo ufw allow 443/tcp # HTTPS If you are planning Python / API (e.g. 8000): sudo...
On your local computer, in your home directory, find the .ssh folder, if it doesn't exist, create it. mkdir ~/.ssh For the first login via SSH, we write in the terminal ssh username@your.ip.address When a question appears, do this: Are you sure you want to continue connecting (yes/no/[fingerprint])? yes Be sure to answer yes not y After this: The key will be saved in ~/.ssh/known_hosts SSH will ask for the user's password. Now,...
Cookie Notice GDPR displays a cookie notice at the bottom of the site for first-time visitors with customizable text, button, and GDPR policy link. Description Cookie Notice GDPR allows WordPress site owners to display a cookie consent notice at the bottom of their website. Features include: * Customizable text for the cookie notice. * Customizable "Accept" button color. * Customizable background color. * Customizable...