Display the total number of posts in WordPress - Display the Total 🔢 Number of Posts in WordPress

Display the Total 🔢 Number of Posts in WordPress

Step 1. Add the following inside your theme functions.php file or create a new Child theme first and add the code to it: Step 2. Add the shortcode [total_posts] anywhere on the website where you want to display the total number of posts: And it will display the number. 🙂

How to remove meta generator tag from WordPress - How to remove meta generator tag from WordPress

How to remove meta generator tag from WordPress

WordPress has an HTML meta generation tag that shows that your website is running WordPress and which version exactly. If you right-click on this page and choose View Source, you can find this tag by searching for “generator” in the source code. You should see something similar to: <meta name=”generator” content=”WordPress 6.0.3″ /> This code … Read full article →

How to delete all comments in WordPress - How to delete all comments in WordPress? 🗑️💬

How to delete all comments in WordPress? 🗑️💬

WordPress uses the wp_commentmeta and wp_comments tables to store comments and their data. To delete all comments in WordPress simply empty those tables in the database: To delete all spam comments use: To delete all unapproved comments use: NOTE: In the above commands change wp_ prefix with the table prefix that you are using *(view … Read full article →

after - How to add text after price in WooCommerce

How to add text after price in WooCommerce

To put a string after the price of WooCommerce product and cart pages, use the WooCommerce filters woocommerce_cart_item_price and woocommerce_get_price_html Add the following code to your active theme functions.php file. Make sure to change <span class=”price-suffix”>TEXT AFTER THE PRICE</span> with your text or HTML code. NEXT: How to Add text before the price in WooCommerce

template name - Display template name in WP admin bar

Display template name in WP admin bar

Figuring out templates that are being used while you are building and developing a custom WordPress website can be problematic. Using the following snippets you can quickly and easily display template name or full path to the file in your wp-admin bar. Display Template name To display just template name add the following to functions.php … Read full article →

wp debug - How to enable WP_DEBUG in WordPress

How to enable WP_DEBUG in WordPress

WP_DEBUG option controls the reporting of some errors and warnings and enables use of the WP_DEBUG_DISPLAY and WP_DEBUG_LOG settings. In this quick tutorial I will show you how to enable the WP_DEBUG feature and output the results to a log file. Enable WP_DEBUG in wp-config.php Edit the wp-config.php file, find this line and change the value … Read full article →