Hook: Customizr Hooks

82 posts

Three techniques to alter the query in WordPress

Howdy WP developer! In this snippet, I will describe three different techniques to alter the WordPress default query with an example showing how to add a secondary page to the front page in the Customizr theme Those are quite advanced WordPress programming techniques, so before diving into it make sure you […]

Change title of time-based archives

If you want to change the titles of daily,monthly or yearly archives, add this to your child theme’s functions.php and modify the archive titles to suit your needs. add_filter(‘tc_time_archive_header_content’,’my_time_archive_header_content’); function my_time_archive_header_content($content) { if ( is_day() || is_month() || is_year() ) { $archive_type = is_day() ? sprintf( __( ‘My Daily Archives: […]

Change the Menu label

The Hamburger Menu or the 3-bar Menu of the Customizr theme has the default label ‘Menu’ next to it. To change the default label to custom text, just paste this function into your child-theme’s functions.php file.   /************************************************************************/ /* Change default menu label ‘Menu’ to ‘Custom Word’ /************************************************************************/ add_filter(‘tc_sidenav_menu_button_view’,’my_menu_label’); function […]

Add a custom Phone Number Font Awesome icon to the Social Icons

Following up the popularity of this Customizr snippet Adding a custom social profile link with icon in the header from Nicolas, we created a variation for adding a custom Font Awesome icon for the phone number. It requires a small function into our child-theme file functions.php. The following snippet includes […]

Enable Dashicons in WordPress Frontend

To use Dashicons (the default set used in the WP backend) we need to enable them also for the front-end of our WordPress site, because by default WP allows Dashicons only for the back-end or for registered admins. Paste this code into your functions.php file /********************************************************/ // Adding Dashicons in […]

How to apply the Lightbox effect to the single post featured image in the Customizr(-Pro) theme

As you surely know you can display the featured image in single post contexts, with the option located at Appearance -> Customize -> Content: home, posts, … -> Single posts Once enabled Customizr(-Pro) will show either the featured image (also called ‘post thumbnail’) or the first post attachment, if the […]

How to display the Category/Tag description in a different place in the Customizr(-Pro) theme

By default Customizr(-Pro) displays the Category/Tag description after the title. You might want to display it in a different place. With the following snippet we’ll see how to display it below the posts navigation. $term_description_filters = array( ‘cat’, ‘tag’, ‘tax’ ); //do not automatically show term descriptions below the title […]

Change the word HOME in the breadcrumb trail

Updated February 24, 2016: Added the option to output either some text or a Font Awesome icon. In case you want to change the default word “Home” in the breadcrumb trail, to something different, this snippet will allow to change it. To use standard characters: just paste this function into […]