-
·
How to put the site in maintenance mode
WP-CLI offers a command to enable, disable maintenance mode and check if maintenance mode is enabled or not. Step 1 – Check the status $ wp maintenance-mode status Maintenance mode is not active. Step 2 – Enable maintenance mode $ wp maintenance-mode activate Enabling Maintenance mode… Success: Activated Maintenance mode. Step 3 – Disable maintenance…
-
·
How to start the webserver
You can use the command wp server to launches PHP’s built-in web server for a specific WordPress installation. By default, the webserver will start using the localhost and default port 8080 but, you can change them using the –host and –port options. Step 1 – Start the web server using the default settings $ wp…
-
·
Internal API
WP-CLI includes a number of utilities which are considered stable and meant to be used by commands. This also means functions and methods not listed here are considered part of the private API. They may change or disappear at any time. Internal API documentation is generated from the WP-CLI codebase on every release. To suggest…
-
·
WP-CLI Hack Day
Welcome to WP-CLI Hack Day! We appreciate you taking time to contribute to the project. We’d love to help you submit at least one pull request today. Given this goal, you’ll likely want to start with something small and attainable. After you’ve submitted your first pull request for the day, you’re welcome to work on…
-
·
Installing
Requirements WP-CLI requires PHP 7.2.24 or later. To check the version of PHP available on your system, run: php –version WP-CLI has no additional requirements beyond those of WordPress itself. Recommended installation The recommended way to install WP-CLI is by downloading the Phar build (archives similar to Java JAR files, see this article for more…
-
·
How to WP-CLI
Introduction Using WP-CLI, you can perform specific tasks using the command line instead of accessing the WordPress admin panel. In the following section, we will cover step by step some of these tasks. How-to install WordPress How to put the website in maintenance mode How-to start the webserver How to create a custom plugin Figure…
-
·
Hosting Companies
The following is a list of hosting companies that have WP-CLI installed by default for their customers, i.e. when they first SSH into their server, the wp command is already available. In alphabetical order: 2020Media 20i 34SP.com A2 Hosting Alldomains.Hosting Altis Cloud Platform AltusHost Amimoto BigCloudy Bluehost Cyberfusion Hypernode CloudHostWorld Cloudways Convesio Curanet D9 Hosting…
-
·
Identify a Plugin or Theme Conflict
Is WP-CLI not working with your WordPress install, but you don’t know why? It might be a plugin or theme conflicting with the WP-CLI load process. To verify, first run wp –skip-plugins –skip-themes to execute WP-CLI without loading plugins or themes. If WP-CLI runs as expected with plugins and themes skipped, then the problem is…
-
·
Implementation Details
This page contains some history on various implementation details of WP-CLI. Bootstrapping WordPress On a normal web request, your web server calls the index.php file in the root of the web directory to bootstrap the WordPress load process: <?php /** * Front to the WordPress application. This file doesn’t do anything, but loads * wp-blog-header.php…
-
·
Pull Requests
WP-CLI follows a pull request workflow for changes to its code (and documentation). Whether you want to fix a bug or implement a new feature, the process is pretty much the same: Search existing issues; if you can’t find anything related to what you want to work on, open a new issue in the appropriate…