LLMS_Table_Students::parse_args( array $args = array() )

Parse arguments passed to get_results() method & setup table class variables.


Parameters Parameters

$args

(array) (Optional) Array of arguments.

Default value: array()


Top ↑

Return Return

(void)


Top ↑

Source Source

File: includes/admin/reporting/tables/llms.table.students.php

	protected function parse_args( $args = array() ) {

		if ( ! $args ) {
			$args = $this->get_args();
		}

		$args = $this->clean_args( $args );

		if ( isset( $args['page'] ) ) {
			$this->current_page = absint( $args['page'] );
		}

		$this->order   = isset( $args['order'] ) ? $args['order'] : $this->get_order();
		$this->orderby = isset( $args['orderby'] ) ? $args['orderby'] : $this->get_orderby();

		$this->per_page = isset( $args['per_page'] ) ? $args['per_page'] : $this->get_per_page();

		if ( $this->is_filterable ) {
			$this->filterby = isset( $args['filterby'] ) ? $args['filterby'] : $this->get_filterby();
			$this->filter   = isset( $args['filter'] ) ? $args['filter'] : $this->get_filter();
		}

		if ( isset( $args['search'] ) ) {
			$this->search = $args['search'];
		}

	}


Top ↑

Changelog Changelog

Changelog
Version Description
3.31.0 Added logic to parse 'filterby' and 'filter' args when this table is filterable.
3.28.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

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