If in one of my previous articles we added data attributes to images upon adding a new image to the content, what can you do if the images are already there? Can you add a data attribute automatically to all images in all posts and pages in WordPress? Let’s say we want to implement Lightbox2 […]
Category: Wordpress tutorials
When developing WordPress theme or working on customization for a client you often need to make incremental updates to the css file. Trouble is that the browsers caches the css files and you can’t see what you did on the the spot. If you know the pain, well, there is a solution.
If you need to redirect all posts from a category to a different domain you can do this very easily from functions.php
If you have a VPS (Virtual Private Server) installed on a main server via KVM you might need at some point to increase the HDD size of the VPS. To do this there are 2 steps: Increase the KVM VSP image size Increasing the usable space for the Linux VPS For this tutorial we are […]
Using GIT to do versioning on your code or sharing work with your colleagues might sound scary. You have to understand how and where your code goes and you have to do it via command line… Just scary.
What if you need to display the grandchildren categories from a known category? In this tutorial I will show you one way to browse through categories with get_categories and list the names of the grandchildren categories on a page.
Printing PDF from the database content in WordPress is relatively easy with the help of the help of mpdf library, but you will need ssh access to the server to install it via composer. You should create HTML code as for a normal web page and the mpdf library will turn everything in PDF. Installing […]
How can you show or hide an input field based on a select value in a HTML form? That’s easy with jQuery. Let’s say you have a form where the user can select a district: and if their district is not in the list, the form shows a field to add a new district (note: […]
There are more ways to protect your entire WordPress site, but if you want to make the site accessible only to registered users then you should apply the WordPress login form to any page before it gets loaded. While there are plugins to do this, password protecting the entire site is done easily by coding […]
On a Ubuntu 16.04 server running MySQL 5.7.7 or higher, the default Plesk backup might show a database warning: plesk (Errcode: 24 – Too many open files) when using LOCK TABLES. This is quite easy to fix. Login to the server via SSH and perform the following operations: create a folder mysql.service.d in /etc/systemd/system/ #mkdir […]