LLMS_Abstract_Query::setup_args()
Setup arguments prior to a query.
Return Return
(void)
Source Source
File: includes/abstracts/llms-abstract-query.php
558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 | protected function setup_args() { $this ->arguments = wp_parse_args( $this ->arguments_original, $this ->arguments_default ); $this ->parse_args(); if ( ! $this ->get( 'suppress_filters' ) ) { /** * Filters the parsed query arguments. * * The dynamic part of the filter `$this->id` identifies the extending query. * * @since 4.5.1 * * @param array $ars The query parse arguments. * @param LLMS_Database_Query $db_query The LLMS_Database_Query instance. * @param array $original_args Original arguments before merging with defaults. * @param array $default_args Default arguments before merging with original. */ $this ->arguments = apply_filters( "llms_{$this->id}_query_parse_args" , $this ->arguments, $this , $this ->arguments_original, $this ->arguments_default ); } foreach ( $this ->arguments as $arg => $val ) { $val = 'sort' === $arg ? $this ->sanitize_sort( $this ->arguments[ 'sort' ] ) : $val ; $this ->set( $arg , $val ); } } |
Expand full source code Collapse full source code View on GitHub
Changelog Changelog
Version | Description |
---|---|
6.0.0 | Moved from LLMS_Database_Query abstract. |
4.5.1 | Added filter "llms_{$this->id}_query_parse_args" . |
3.8.0 | |
3.34.0 | Introduced. |