Skip to content
  • Blog (1)
  • About Us
  • Tags
  • Donations
1SMARTchicken - Code Made Easy
  • Tutorials (176)
  • Reference (2172)
  • Snippets (69)

Category: WordPress Snippets

1SMARTchicken - Code Made Easy

Category: WordPress Snippets

  • Tutorials (176)
  • Reference (2172)
  • Snippets (69)
  • Blog (1)
  • About Us
  • Tags
  • Donations
1SMARTchicken - Code Made Easy
  • Tutorials (176)
  • Reference (2172)
  • Snippets (69)
1SMARTchicken - Code Made Easy

Category: WordPress Snippets

  • Tutorials (176)
  • Reference (2172)
  • Snippets (69)
  • Home
  • Snippets
  • WordPress Snippets
WordPress Snippets

WordPress – Add a Clear Cart Button to WooCommerce

January 28, 2025 / Snippets, WordPress Snippets / WooCommerce

When a user is in the WooCommerce checkout, they’ll find that the “Ship to a Different Address” box checked is by default.

WordPress Snippets

WordPress – Add a Custom User Avatar

July 30, 2024 / Snippets, WordPress Snippets / Backend, Image

In the discussion settings of WordPress sites a custom avatar can be placed that can be used by the users on your site when joining to place comments.

WordPress Snippets

WordPress – Add a Page Title to All Page/Post Types

January 29, 2025 / Snippets, WordPress Snippets / Shortcode

There are times when you may need a shortcode to add the current page or post title somewhere on your site.

WordPress Snippets

WordPress – Add an Excerpt to WooCommerce Grid Items

July 30, 2024 / Snippets, WordPress Snippets / WooCommerce

When using WooCommerce on a WordPress site, you can show the products on the shop page as a grid, but not all themes show the product’s short description.

WordPress Snippets

WordPress – Add an Excerpt Widget to the Backend of Pages

July 30, 2024 / Snippets, WordPress Snippets / Backend

The backend of a WordPress site has pages, post, etc. But on the pages, there is no area for writing a short description. This code adds that functionality.

WordPress Snippets

WordPress – Add Post Counts to Menu Category Links

July 30, 2024 / Snippets, WordPress Snippets / Link

The number of posts contained in each WordPress category (post count) can be displayed in the main menu when using categories as links.

WordPress Snippets

WordPress – Break a Site Out of Another URL’s Frames

July 30, 2024 / Snippets, WordPress Snippets / Link, Security

There have been times where I’ve found that one of my sites was showing completely under another individual’s URL. They embedded my site in their frames.

WordPress Snippets

WordPress – Change Automatic Compression of JPGs

July 30, 2024 / Snippets, WordPress Snippets / Image

By default WordPress compresses uploaded JPGs to 90% of their original quality, which can have undesirable results. This compression can be turned off.

WordPress Snippets

WordPress – Change Button Text in a WooCommerce Grid

July 30, 2024 / Snippets, WordPress Snippets / WooCommerce

When using WooCommerce on a WordPress site, the buttons on the shop-page, product-grid items says “add to cart”, but it can be changed to suit your needs.

WordPress Snippets

WordPress – Change the Breakpoint for the Astra Theme

January 28, 2025 / Snippets, WordPress Snippets / Astra Theme

When using WooCommerce on a WordPress site, the buttons on the shop-page, product-grid items says “add to cart”, but it can be changed to suit your needs.

WordPress Snippets

WordPress – Check WooCommerce Create an Account by Default

July 30, 2024 / Snippets, WordPress Snippets / WooCommerce

In WooCommerce, when a guest customer checks out there will be a “Create an Account” checkbox, which is not checked by default. We can change the default.

WordPress Snippets

WordPress – Close an Elementor Popup with a Custom Link

July 30, 2024 / Snippets, WordPress Snippets / Elementor, Plugin

When creating a popup in Elementor it can be given a button using the button widget for closing the popup. JavaScript can also be utilized to close it.

WordPress Snippets

WordPress – Create a Published Date Shortcode

July 30, 2024 / Snippets, WordPress Snippets / Shortcode

A “published date” shortcode can be created and placed in your functions.php document to be used in various places in your pages, posts, or site sections.

WordPress Snippets

WordPress – Customize the Howdy Text on the Admin Bar

July 30, 2024 / Snippets, WordPress Snippets / Backend

In the WordPress backend, on the admin bar, there has always been the “Howdy” text that greets you and leads to your account info. It can be customized.

WordPress Snippets

WordPress – Customize the wp-login.php Page Appearance

March 9, 2025 / Snippets, WordPress Snippets / Backend

The WordPress login page is fairly plane and has the WordPress logo. It can be customized to represent your company’s brand or the site itself.

WordPress Snippets

WordPress – Disable Comments in the Front and Back End

July 30, 2024 / Snippets, WordPress Snippets / Backend

If your site doesn’t use comments and you want to remove their menu items from showing in the back end, this can be done in your functions.php file.

WordPress Snippets

WordPress – Disable Specific Plugin Update Notifications

July 30, 2024 / Snippets, WordPress Snippets / Backend, Plugin

Occasionally, you may want to temporarily hide update notifications for a WordPress site because you aren’t updating the plugin for some reason.

WordPress Snippets

WordPress – Disable Barn2 Variation Table Sorting

September 11, 2024 / Snippets, WordPress Snippets / Plugin

If you use the Barn2 WooCommerce Product Table plugin, there may be a reason you want to disable the column sorting.

WordPress Snippets

WordPress – Disable Widget Blocks and Restore Classic Widgets

July 30, 2024 / Snippets, WordPress Snippets / Backend

If you don’t use Gutenberg to build your WordPress pages, you may want to disable blocks and restore the classic widgets in the backend of your site.

WordPress Snippets

WordPress – Enqueue a JavaScript Document

March 9, 2025 / Snippets, WordPress Snippets

To enqueue a JavaScript file in WordPress, you use the wp_enqueue_script function in your theme’s functions.php file.

1 2 Next →

or View All Tags

Tutorials

  • HTML Tutorials (40)
  • CSS Tutorials (45)
    • CSS Flexbox (12)
  • JavaScript Tutorials (6)
  • jQuery Tutorials (13)
  • PHP Tutorials (0)
  • SQL Tutorials (0)
  • Python Tutorials (72)
    • Python File Handling (4)
    • Python and MySQL (4)
  • WordPress Tutorials (0)

Reference

  • HTML Reference (244)
    • HTML Tags (107)
    • HTML Attributes (46)
    • HTML Events (76)
    • HTML Resources (15)
  • CSS Reference (309)
    • CSS Selectors (55)
    • CSS Properties (220)
    • CSS Functions (17)
    • CSS Resources (17)
  • JavaScript Reference (555)
    • JavaScript Selectors (7)
    • JavaScript Operators (12)
    • JavaScript Statements (17)
    • JavaScript Methods (284)
    • JavaScript Properties (162)
    • JavaScript RegExp (45)
    • JavaScript Resources (28)
  • jQuery Reference (220)
    • jQuery Selectors (54)
    • jQuery Methods (140)
    • jQuery Ajax Methods (16)
    • jQuery Properties (17)
    • jQuery Resources (9)
  • PHP Reference (460)
    • PHP Keywords (59)
    • PHP Functions (400)
    • PHP Constants (0)
    • PHP Resources (1)
  • SQL Reference (290)
    • SQL Keywords (59)
    • MySQL Functions (138)
    • SQL Server Functions (83)
    • SQL Resources (10)
  • Python Reference (94)
    • Python Methods (86)
    • Python Resources (8)
  • WordPress Reference (0)

Snippets

  • HTML Snippets (3)
  • CSS Snippets (12)
  • JavaScript Snippets (5)
  • jQuery Snippets (8)
  • PHP Snippets (1)
  • SQL Snippets (3)
  • Python Snippets (1)
  • WordPress Snippets (36)
1SMARTchicken - Code Made Easy

333 Washington Blvd.
Suite 126
Marina del Rey, CA 90292
United States

contact2025@1smartchicken.com

  • About Us
  • Privacy Policy
  • Cookie Policy
  • Terms & Conditions

Search for Code:

or View All Tags

Copyright © 2025 1SMARTchicken | All Rights Reserved.