Created
May 24, 2013 00:15
-
-
Save LinzardMac/5640482 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Retrieve variable in the WP_Query class. | |
* | |
* @see WP_Query::get() | |
* @since 1.5.0 | |
* @uses $wp_query | |
* | |
* @param string $var The variable key to retrieve. | |
* @return mixed | |
*/ | |
function get_query_var($var) { | |
global $wp_query; | |
//line 27 below | |
return $wp_query->get($var); | |
} | |
/** | |
* Retrieve the currently-queried object. Wrapper for $wp_query->get_queried_object() | |
* | |
* @uses WP_Query::get_queried_object | |
* | |
* @since 3.1.0 | |
* @access public | |
* | |
* @return object | |
*/ | |
function get_queried_object() { | |
global $wp_query; | |
return $wp_query->get_queried_object(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment