Register widget in functions.php
// ========================================================================= // REGISTER NEW WIDGET // ========================================================================= function custom_widgets_init() { register_sidebar( array( 'name' => 'Custom Widget', 'id' => 'custom-widget-id', 'before_widget' => '<div class="custom-widget">', 'after_widget' => '</div>', 'before_title' => '<h4 class="custom-title">', 'after_title' => '</h4>', ) ); } add_action( 'widgets_init', 'custom_widgets_init' );
Place this code where you want to appear the widget
<?php dynamic_sidebar('Custom Widget'); ?>
Recent Snippets
Force full-width layout on specific single page in Genesis
Universal Parallax in Genesis
Change Genesis Search Widget’s Placeholder Text
Change breadcrumbs home text in Genesis
Remove sidebar from cart and checkout page in Genesis WooCommerce
Custom single post template for specific category in Genesis
Custom Post Type Pagination in Genesis
Echo something conditionally on the single page of specific Custom Post Type Taxonomy
Split Menu Around the Logo in Genesis Sample
How to remove ‘Menu’ text in Genesis mobile navigation
How to force hamburger menu on desktop in Genesis
Add Three Column Layout to Genesis Front Page and Two Column for Other Pages
Remove “You are here” from Genesis breadcrumb
How to add SVG logo to Genesis
Genesis translations
Add page title with featured image in Genesis
Hide header when scrolling down, show it when scrolling up in Genesis
Genesis Loop with Pagination
Full-width hero image on category / tag / taxonomy archive pages in Genesis
How to add Page Title Background with ACF