How to get WordPress image link from the media ID
In this example, I’m using ID 14988 Using Media Library If you are logged in as admin, add the media ID in the website URL: then copy the file URL: Using SQL Using WPCLI or
💡 WP-CLI is the command-line interface for WordPress that lets you manage your WordPress site, themes, and plugins from the terminal.
Here you can find most useful WP-CLI commands and tutorials.
In this example, I’m using ID 14988 Using Media Library If you are logged in as admin, add the media ID in the website URL: then copy the file URL: Using SQL Using WPCLI or
Here is a convenient WP-CLI command that I use when cleaning hacked WordPress websites in order to reinstall all plugins from WordPress.org It consists of two commands: get a list of all active plugins, then force reinstall for each plugin. To reinstall all WordPress themes in the same manner use:
In this post, I will be using 3 free tools to scan WordPress websites for vulnerabilities. NAME PLATFORM HOW TO USE LIMITS WPScan Windows & Linux terminal free plan: 25 reports daily WPSEC website online free plan: 20 scans daily Burp Suite Windows & Linux application ∞ 1. From the terminal: WPScan If you have … Read full article →
Packages can be installed to add functionality to WP-CLI, for example wp-cli/wp-super-cache-cli package will add functions for managing WP Super Cache plugin from the terminal. Here is a list of My favourite packages from the wp-cli/package-index: billerickson/wp-cli-plugin-install-missing install any plugins that are “active” but not installed binarygary/db-checkpoint create quick db snapshots for development purposes jaywood/jw-wpcli-random-posts … Read full article →
In this guide We’ll cover how to reset a WordPress user password using WP-CLI. Step 1. Ensure WP-CLI is installed and you are in the website directory run the following command to check if you are in the right folder: Step 2. List all users and note user_login for the user Step 3. Replace the … Read full article →
Deleting all inactive WordPress themes and plugins from your website is a recommended security practice. Even when deactivated, old, insecure plugins and themes might still pose a threat to the security of your WordPress website. Here are oneliners to remove inactive themes and plugins from your WordPress website using WP-CLI. List all inactive WordPress themes: Delete … Read full article →
IF you use the same commands often you can save them as aliases so that you have them always available. For example, the following commands will check if WP core, installed plugins and themes have updates available: You can combine the commands into a one-liner: and you can create an alias for this command: so … Read full article →
The principle of WPCLI is to add install it on the server, add it to path so that it can be accessed from any folder and then enter the installation folder of the website for which you want to run commands. The basic use of WP-CLI is: wp [COMMAND], e.g. wp config list will show … Read full article →
When migrating from WordPress CMS to another CMS there are a couple of ways to easily export all your posts and media files: In this guide we will be using the WPGraphQL plugin and Netlify to deploy a Gatsby website. Step 1. Fork the gatsbyjs/gatsby-starter-wordpress-blog repo on Github Step 2. Edit the gatsby-config.js file and … Read full article →
WordPress uses transients to temporarily store data for its plugins and themes. By managing transients you can optimize your website for speed and make sure your website is always functioning properly. Here are a few methods how to safely delete expired WordPress transients: Delete Expired WordPress Transients using WPCLI To delete only expired transients use: … Read full article →