By Stephen Walker

Share

This will add the link to the interface for managing reusable blocks to the WordPress side menu.

Snippet

Add this to your functions.php, or your preferred code snippet manager.

function be_reusable_blocks_admin_menu() {
add_menu_page( 'Reusable Blocks', 'Reusable Blocks', 'edit_posts', 'edit.php?post_type=wp_block', '', 'dashicons-editor-table', 22 );
 }
add_action( 'admin_menu', 'be_reusable_blocks_admin_menu' );

Originally published on Dec. 18, 2022

Today's Date
Styling Avada Filters

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

RELATED Snippets

  • ChatGPT, PHP

    I prefer to have my dates in human-readable time difference or AP style dates, so this function will replace the default date format and output either the human-readable time difference or if the date difference is more than 180 days, the AP Style date.

  • ChatGPT, PHP, Shortcode

    WordPress has a great function built-in to express the date posted in a more readable format.

  • ChatGPT, PHP

    If you work with numerous non-published posts, it might be helpful to show the status. This shortcode shows the status if the status is currently not “Publish.”

  • ChatGPT, PHP, Shortcode

    I used ChatGPT to generate a shortcode that would indicate whether a business is opened or closed.

  • Advanced Custom Fields (ACF), PHP, Plugins

    Since ACF turns off the WordPress custom fields, this snippet will bring them back. Just add it to your functions.php or your favorite code manager

  • PHP, Shortcode

    I wanted to show the date the article was posted and the date updated if the dates differ. This shortcode will do just that.