bp_nouveau_get_filter_options()

Get the <option> of the data filter’s <select> element.


Return Return

(string)


Source Source

File: bp-templates/bp-nouveau/includes/template-tags.php

	function bp_nouveau_get_filter_options() {
		$output = '';

		if ( bp_nouveau_get_component_slug( 'notifications' ) === bp_current_component() ) {
			$output = bp_nouveau_get_notifications_filters();

		} else {
			$filters = bp_nouveau_get_component_filters();

			foreach ( $filters as $key => $value ) {
				$output .= sprintf( '<option value="%1$s">%2$s</option>%3$s',
					esc_attr( $key ),
					esc_html( $value ),
					PHP_EOL
				);
			}
		}

		return $output;
	}


Top ↑

Changelog Changelog

Changelog
Version Description
3.0.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.