Make WordPress Core

Changeset 16352


Ignore:
Timestamp:
11/13/2010 06:26:15 PM (16 years ago)
Author:
scribu
Message:

Revert most of [16018]. See #15032

Location:
trunk/wp-includes
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/class-wp-object-query.php

    r16351 r16352  
    99 */
    1010class WP_Object_Query {
    11 
    12         /**
    13          * Query vars, after parsing
    14          *
    15          * @since 3.1.0
    16          * @access public
    17          * @var array
    18          */
    19         var $query_vars;
    20 
    21         /**
    22          * Retrieve query variable.
    23          *
    24          * @since 3.1.0
    25          * @access public
    26          *
    27          * @param string $query_var Query variable key.
    28          * @return mixed
    29          */
    30         function get( $query_var ) {
    31                 if ( isset( $this->query_vars[$query_var] ) )
    32                         return $this->query_vars[$query_var];
    33 
    34                 return '';
    35         }
    36 
    37         /**
    38          * Set query variable.
    39          *
    40          * @since 3.1.0
    41          * @access public
    42          *
    43          * @param string $query_var Query variable key.
    44          * @param mixed $value Query variable value.
    45          */
    46         function set( $query_var, $value ) {
    47                 $this->query_vars[ $query_var ] = $value;
    48         }
    49 
    5011        /*
    5112         * Populates the $meta_query property
  • trunk/wp-includes/query.php

    r16303 r16352  
    690690 */
    691691class WP_Query extends WP_Object_Query {
    692         /**
    693          * Initial query vars
     692
     693        /**
     694         * Query vars set by the user
    694695         *
    695696         * @since 1.5.0
    … …  
    698699         */
    699700        var $query;
     701
     702        /**
     703         * Query vars, after parsing
     704         *
     705         * @since 1.5.0
     706         * @access public
     707         * @var array
     708         */
     709        var $query_vars = array();
    700710
    701711        /**
    … …  
    16051615
    16061616        /**
     1617         * Retrieve query variable.
     1618         *
     1619         * @since 1.5.0
     1620         * @access public
     1621         *
     1622         * @param string $query_var Query variable key.
     1623         * @return mixed
     1624         */
     1625        function get($query_var) {
     1626                if ( isset($this->query_vars[$query_var]) )
     1627                        return $this->query_vars[$query_var];
     1628
     1629                return '';
     1630        }
     1631
     1632        /**
     1633         * Set query variable.
     1634         *
     1635         * @since 1.5.0
     1636         * @access public
     1637         *
     1638         * @param string $query_var Query variable key.
     1639         * @param mixed $value Query variable value.
     1640         */
     1641        function set($query_var, $value) {
     1642                $this->query_vars[$query_var] = $value;
     1643        }
     1644
     1645        /**
    16071646         * Retrieve the posts based on query variables.
    16081647         *
Note: See TracChangeset for help on using the changeset viewer.