add querystring to page caching. #2349
diff --git a/system/core/Output.php b/system/core/Output.php
index 8b7d6ef..4743690 100644
--- a/system/core/Output.php
+++ b/system/core/Output.php
@@ -564,6 +564,9 @@
 			.$CI->config->item('index_page')
 			.$CI->uri->uri_string();
 
+		// append querystring
+      $uri .= (empty($_SERVER['QUERY_STRING'])) ? '' : '?' . $_SERVER['QUERY_STRING'];      
+
 		$cache_path .= md5($uri);
 
 		if ( ! $fp = @fopen($cache_path, 'w+b'))
@@ -648,6 +651,9 @@
 
 		// Build the file path. The file name is an MD5 hash of the full URI
 		$uri =	$CFG->item('base_url').$CFG->item('index_page').$URI->uri_string;
+		// append querystring
+      $uri .= (empty($_SERVER['QUERY_STRING'])) ? '' : '?' . $_SERVER['QUERY_STRING'];
+
 		$filepath = $cache_path.md5($uri);
 
 		if ( ! file_exists($filepath) OR ! $fp = @fopen($filepath, 'rb'))
@@ -727,6 +733,9 @@
 			$uri = $CI->uri->uri_string();
 		}
 
+		// append querystring
+      $uri .= (empty($_SERVER['QUERY_STRING'])) ? '' : '?' . $_SERVER['QUERY_STRING'];
+
 		$cache_path .= md5($CI->config->item('base_url').$CI->config->item('index_page').$uri);
 
 		if ( ! @unlink($cache_path))