• Home
  • Getting Started
  • Home
  • Getting Started

Theme Hooks

Theme hooks allows you to hook into a theme functionality without modifying the core files. Read more about Actions and Filters API here – https://codex.wordpress.org/Plugin_API

How to use Hooks.

In your child theme edit functions.php and add your scripts. Let’s say you want to add something before sidebar, we’ll use dinery_sidebar_before hook. The code example would be:

PHP
1
2
3
4
add_action( 'dinery_sidebar_before', 'dinery_add_sidebar_message' );
function dinery_add_sidebar_message() {
  echo esc_html__( 'Sidebar Message', 'dinery' );
}

List of available Hooks:

  • dinery_head_top()
  • dinery_head_bottom()
  • dinery_header_before()
  • dinery_header()
  • dinery_header_after()
  • dinery_masthead()
  • dinery_body_top()
  • dinery_body_bottom()
  • dinery_primary_content_top()
  • dinery_primary_content_before()
  • dinery_primary_content_query()
  • dinery_primary_content_after()
  • dinery_primary_content_bottom()
  • dinery_comments_before()
  • dinery_comments()
  • dinery_comments_after()
  • dinery_entry_section_before()
  • dinery_entry_header_before()
  • dinery_entry_header()
  • dinery_entry_header_after()
  • dinery_entry_featured_image()
  • dinery_entry_content_top()
  • dinery_entry_content_bottom()
  • dinery_page_title_before()
  • dinery_page_title_after()
  • dinery_sidebar_before()
  • dinery_sidebar_after()
  • dinery_footer_before()
  • dinery_footer()
  • dinery_footer_after()

 

 

Was this helpful?

Yes  No
Related Articles
  • GDPR
  • Multilingual Management With WPML
  • Theme Translation
  • Site Performance

No luck finding what you need? Contact Us

Others
  • Theme Hooks
  • GDPR
  • Multilingual Management With WPML
  • Theme Translation
  • Site Performance
Categories
  • Blog
  • Customization
  • Elementor
  • Getting Started
  • Others
  • Pages

  Theme Translation

Site Performance  

  • © 2025 deothemes.com. All Rights Reserved.