How to change the widget HTML by a child WordPress theme

This is very simple and you can do it in this way: add_filter(‘dynamic_sidebar_params’, ‘yourtheme_change_widget_head’); function yourtheme_change_widget_head( $params ) { if ( $params[0][‘id’] === ‘footer-sidebar-2’ ) { $params[0][‘before_title’] = ‘<h4 class=”widget-title”>’; $params[0][‘after_title’] = ‘</h4>’; } return $params; } This filter allows you to check what is executed by dynamic_sidebar as parameter. So first of all you […]

Read More…