WC_Query::get_current_endpoint()

Get query current active query var.


Description Description


Return Return

(string)


Top ↑

Source Source

File: includes/class-wc-query.php

	public function get_current_endpoint() {
		global $wp;

		foreach ( $this->get_query_vars() as $key => $value ) {
			if ( isset( $wp->query_vars[ $key ] ) ) {
				return $key;
			}
		}
		return '';
	}


Top ↑

User Contributed Notes User Contributed Notes

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