Running a WordPress website on Ubuntu 20.04 with Nginx

Ubuntu 20.04: WordPress with Nginx installation

WordPress is an extremely popular content management system (CMS) for websites. Its popularity and ubiquity really cannot be overstated, as it powers a staggering 35% of websites. It’s an easy way to get a website online, and it offers a lot in the way of customization.

Ubuntu 20.04 Focal Fossa and Nginx are the perfect combination to run your WordPress site. Using these utilities will give you a very powerful, efficient, and stable website. Best of all, all this software is completely free and the setup isn’t very difficult. Follow along with our steps below to see how to get your WordPress site up and running on Ubuntu 20.04 with Nginx.

If you’re more familiar with or happen to prefer Apache over Nginx, we’ve written a separate guide for Ubuntu 20.04 WordPress installation on Apache.

In this tutorial you will learn:

  • How to install and configure Nginx
  • How to install and configure MariaDB for MySQL
  • How to setup a MySQL database for WordPress
  • How to download and install WordPress
  • How to configure SSL for your WordPress site

Read more

Using cookies in PHP

How to enable sessions in PHP with cookies

Cookies are all around in our everyday life while we browse the Internet. Most people wouldn’t know much about them, if not for those “our website uses cookies to be operational” signs that are on mostly any page now since GDPR. Cookies have a long history if sometimes being good, sometimes bad. As it is usual with most aspects of the world, this technology can be used in a good or bad way.

In this tutorial we will explore cookies a bit from the server side programming perspective: we’ll create an example cookie in PHP, and store the visitor’s chosen username in it. The cookie will reside in the browser of the visitor, so on the next visit we can read it and use it to greet the visitor on the username submitted.

Our simple webpage will recognize the visitor as long as the cookie is present in the browser. We do not store any information on the server side: if the visitor first checks in from a PC, and next time from a smartphone, we will not know it is the same individual. This is one of the main point with cookies: we can only identify the given client, and only as long as the data is provided by that particular browser.

In this tutorial you will learn:

  • How to setup the test environment
  • How to write a simple example program that uses cookies
  • How to test the workings of the program
  • How to reset the environment

Read more

How to setup Nginx Reverse Proxy

How to setup Nginx Reverse Proxy

In this guide, you will learn how to setup an Nginx reverse proxy with step by step instructions. We will also explain how a reverse proxy server works and what its advantages are. In addition, we also go over various configuration options that Linux administrators commonly employ on their reverse proxy servers.

In this tutorial you will learn:

  • How does a reverse proxy work
  • What are the benefits of a reverse proxy
  • How to setup Nginx reverse proxy
  • How to pass headers
  • How to configure load balancing
  • How to test the Nginx configuration

Read more

Nginx web-server on RHEL 8 Linux server.

How to install nginx on RHEL 8 / CentOS 8 server

The aim of this article is to get you started with basic Nginx web-server installation using the dnf install nginx command and configuration on RHEL 8 / CentOS 8. Nginx web server is an Apache alternative with a capability to be also used as reverse proxy, load balancer, mail proxy and HTTP cache.

In this tutorial you will learn:

  • How to install Nginx on RHEL 8 / CentOS 8.
  • How to start Nginx.
  • How to enable Nginx to start after reboot.
  • How to open HTTP and HTTPS ports.
  • How to run Nginx encrypted with HTTPS.
  • How to create self-signed SSL certificate for Nginx.

Read more

PHPinfo on LEMP on Debian 10

How to Set Up a LEMP Server on Debian 10 Buster

LEMP is an excellent alternative to traditional LAMP servers. Nginx is lighter weight and faster than Apache in some situations. It can also be configured to do other useful things, like serve as a reverse proxy. Just like with LAMP, Debian is an excellent platform for LEMP servers. Everything you need is available in the Debian repositories, so it’s simple to get started.

In this tutorial you will learn:

  • How to Set Up MariaDB
  • How to Install PHP
  • How to Install Nginx
  • How to Configure Nginx
  • How to Test Your Server

Read more