bws_add_filter_for_widget_type

The Bootstrap Widget Styling bws add filter for widget type function.

Description

bws_add_filter_for_widget_type( $type ); 

Parameters (1)

0. $type
The type.

Usage

  1. if ( !function_exists( 'bws_add_filter_for_widget_type' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'bootstrap-widget-styling/includes/bws-widget-filters.php'; 
  3.  
  4. // The type. 
  5. $type = null; 
  6.  
  7. // NOTICE! Understand what this does before running. 
  8. $result = bws_add_filter_for_widget_type($type); 
  9.  

Defined (1)

The function is defined in the following location(s).

/includes/bws-widget-filters.php  
  1. function bws_add_filter_for_widget_type( $type ) { 
  2. if ( 'archives' === $type ) { 
  3. add_filter( 'get_archives_link' , array( 'BWS_Archives' , 'filter' ) ) ; 
  4. else { 
  5. add_filter( 'wp_list_' . $type , array( 'BWS_' . $type , 'filter' ) ) ;