@@ -60,7 +60,7 @@ function render_wpfc_sorting( $args = array() ) {
6060 $ action = '' ;
6161
6262 // Filters HTML fields data.
63- $ filters = array (
63+ $ filters = apply_filters ( ' render_wpfc_sorting_filters ' , array (
6464 array (
6565 'className ' => 'sortPreacher ' ,
6666 'taxonomy ' => 'wpfc_preacher ' ,
@@ -86,15 +86,15 @@ function render_wpfc_sorting( $args = array() ) {
8686 'taxonomy ' => 'wpfc_service_type ' ,
8787 'title ' => __ ( 'Service Type ' , 'sermon-manager-for-wordpress ' ),
8888 ),
89- );
89+ ) ) ;
9090
91- $ visibility_mapping = array (
91+ $ visibility_mapping = apply_filters ( ' render_wpfc_sorting_visibility_mapping ' , array (
9292 'wpfc_sermon_topics ' => 'hide_topics ' ,
9393 'wpfc_sermon_series ' => 'hide_series ' ,
9494 'wpfc_preacher ' => 'hide_preachers ' ,
9595 'wpfc_bible_book ' => 'hide_books ' ,
9696 'wpfc_service_type ' => 'hide_service_types ' ,
97- );
97+ ) ) ;
9898
9999 // Save orig args for filters.
100100 $ orig_args = $ args ;
@@ -607,7 +607,18 @@ function wpfc_get_term_dropdown( $taxonomy, $default = '' ) {
607607 $ html .= '<option value=" ' . $ term ->slug . '" ' . ( ( '' === $ default ? $ current_slug === $ term ->slug : $ default === $ term ->slug ) ? 'selected ' : '' ) . '> ' . $ term ->name . '</option> ' ;
608608 }
609609
610- return $ html ;
610+ /**
611+ * Allows you to filter the dropdown options (HTML).
612+ *
613+ * @var string $html The existing HTML.
614+ * @var array $taxonomy The taxonomy that is being used.
615+ * @var string $default The forced default value. See function PHPDoc.
616+ * @var array $terms The array of terms, books will already be ordered.
617+ * @var string $current_slug The term that is being requested.
618+ *
619+ * @since 2.15.12
620+ */
621+ return apply_filters ( 'wpfc_get_term_dropdown ' , $ html , $ taxonomy , $ default , $ terms , $ current_slug );
611622}
612623
613624/**
0 commit comments