From 9426478867ba9047e163e1df29a5d9a5fe50de2f Mon Sep 17 00:00:00 2001 From: ryan Date: Tue, 22 Nov 2005 21:07:48 +0000 Subject: [PATCH] Store some values in the class for debug purposes. git-svn-id: http://svn.automattic.com/wordpress/trunk@3197 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/classes.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/wp-includes/classes.php b/wp-includes/classes.php index 2372d1255d..ae75aab410 100644 --- a/wp-includes/classes.php +++ b/wp-includes/classes.php @@ -1401,6 +1401,9 @@ class WP { var $query_vars; var $query_string; + var $request; + var $matched_rule; + var $matched_query; var $did_permalink = false; function parse_request($extra_query_vars = '') { @@ -1451,6 +1454,7 @@ class WP { } else { $request = $req_uri; } + $this->request = $request; // Look for matches. $request_match = $request; @@ -1463,11 +1467,14 @@ class WP { if (preg_match("!^$match!", $request_match, $matches)) { // Got a match. + $this->matched_rule = $match; + // Trim the query of everything up to the '?'. $query = preg_replace("!^.+\?!", '', $query); // Substitute the substring matches into the query. eval("\$query = \"$query\";"); + $this->matched_query = $query; // Parse the query. parse_str($query, $query_vars);