LLMS_Query::__construct()

Constructor.


Source Source

File: includes/class.llms.query.php

	public function __construct() {

		add_action( 'init', array( $this, 'add_endpoints' ) );

		if ( ! is_admin() ) {

			add_filter( 'query_vars', array( $this, 'set_query_vars' ), 0 );
			add_action( 'parse_request', array( $this, 'parse_request' ), 0 );
			add_action( 'wp', array( $this, 'maybe_404_certificate' ), 50 );
			add_action( 'wp', array( $this, 'maybe_redirect_certificate' ), 50 );

		}

		$this->init_query_vars();

		add_action( 'pre_get_posts', array( $this, 'pre_get_posts' ), 15 );

	}


Top ↑

Changelog Changelog

Changelog
Version Description
6.0.0 Add callback to redirect old llms_my_certificates requests to the new url.
4.5.0 Added action to serve 404s on unviewable certificates.
3.36.3 Changed pre_get_posts callback from 10 (default) to15, so to avoid conflicts with the Divi theme whose callback runs at10`, but since themes are loaded after plugins it overrode our one.
3.28.2 Unknown.
1.0.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

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