While nginx microcaching already solves page caching (as of static, rarely changing WordPress pages), the performance for dynamically generated pages (like WooCommerce shop pages and admin backend in general) can benefit greatly from additionally using an object cache. Object caching allows an application (in this case WordPress with its plugins, theme, etc.) to store prepared objects (mostly database queries) in a database and quickly retrieve them, therefore improving the performance of dynamic page generation. Object caching is (usually) transparent, which means that it shouldn't be noticeable by users and developers (except for the performance improvements of course).
<?php | |
namespace App\Livewire; | |
use Livewire\Attributes\Url; | |
use Livewire\Component; | |
use WP_Query; | |
class PostSearch extends Component | |
{ |
<?php | |
/** | |
* Plugin Name: Block Editor Cleanup | |
* Plugin URI: https://github.com/WordPress/gutenberg/issues/38299#issuecomment-1025520487 | |
* Version: 1.0.1 | |
* Description: Remove WP 5.9 default block editor styles when using Classic Editor | |
* Author: joshuafredrickson | |
* Author URI: https://joshuafredrickson.com | |
* License: GNU General Public License v2 | |
* License URI: http://www.gnu.org/licenses/gpl-2.0.html |
This entire guide is based on an old version of Homebrew/Node and no longer applies. It was only ever intended to fix a specific error message which has since been fixed. I've kept it here for historical purposes, but it should no longer be used. Homebrew maintainers have fixed things and the options mentioned don't exist and won't work.
I still believe it is better to manually install npm separately since having a generic package manager maintain another package manager is a bad idea, but the instructions below don't explain how to do that.
Installing node through Homebrew can cause problems with npm for globally installed packages. To fix it quickly, use the solution below. An explanation is also included at the end of this document.
- Initial Server Setup with Ubuntu 12.04
- How To Install Linux, nginx, MySQL, PHP (LEMP) stack on Ubuntu 12.04
- A Basic MySQL Tutorial
- How To Install phpMyAdmin on a LEMP server
- How To Install Git on Ubuntu 12.04
- Generating SSH Keys and connect with DigitalOcean
- Install Composer on DigitalOcean
- [Install php5-cli if you get stuck with installing Compos
<?php | |
/** | |
* Remove unnecessary markup from WooCommerce: | |
* | |
* 1. Remove <meta name="generator" content="WooCommerce (version)" /> | |
* 2. Remove the addition of <body class="theme-themename"> | |
*/ | |
function woocommerce_head_cleanup() { | |
global $woocommerce; |
The script below is triggered every day from my Mac. I use Hazel to move the tar.gz to an external hard disk once it's finished. This happens every day without me noticing. You can exclude folders if you want to. You probably want to exclude giant cache folders.
You should have a similar script.