How to increase PHP file upload limit with PHP FPM and Nginx

If while uploading a file you get an error with the following text in it : “client intended to send too large body:” You can fix this error by increasing the PHP File-Upload Limit as following : Step 1: Open php.ini file nano /etc/php5/fpm/php.ini And update ‘upload_max_filesize’ and ‘post_max_size’ values upload_max_filesize = 150M post_max_size = …

How to stop WordPress from adding ‘p’ tags and line breaks in post content

Often while updating pages or posts in WordPress, it automatically adds p and br tags automatically at the end of paragraphs. This behavior specially happens when copying text from HTML file to the WordPress editor.This can be really frustrating and keeps on messing with the page structure. There are 2 ways of fixing this issue …

How to protect your WordPress site from Brute Force Attacks (WordPress + Nginx + fail2ban)

One of the most common attacks are Brute Force attacks on your WordPress site’s xmlrpc.php or wp-login.php. In a brute force attack the malicious script, which runs off server, tries a number of login combinations until it gains access to the site. We will be using Fail2Ban framework. This framework monitors the server log files …

WordPress Multisite with Nginx

If you are setting up a WordPress multisite, you might notice that the WordPress install displays the Apache settings for the .htaccess file, but does not provide any settings for Nginx. How to setup WordPress Multisite Open the wp-config.php file and add the following line /* Multisite */ define(‘WP_ALLOW_MULTISITE’, true); Select the type of Multisite …