title: Gzcompressed or plain string
body: <p>I have a file <code>plain.cache</code> which is little over 10MB and I made a <a href="http://php.net/manual/en/function.gzcompress.php" rel="nofollow noreferrer">gzcompressed</a> file <code>gz.cache</code> out of the original <code>plain.cache</code> file. Then, I made two separate files which load each of the mentioned cache files and was kind of surprised that the page load speed of both files was <a href="http://whichloadsfaster.com/?l=nikola-breznjak.com/_testings/plain.php&amp;r=nikola-breznjak.com/_testings/gz.php" rel="nofollow noreferrer">almost the same</a>. So, my question is - am I being right by concluding that <code>gzcompressed</code> file does not in any way benefit the load speed of the page? Now, I would conclude that the <a href="http://php.net/manual/en/function.gzuncompress.php" rel="nofollow noreferrer">gzuncompress</a> that I use in the <code>gz.php</code> file "makes" the same exact string just as when I read it from the plain file. Given all these staments - a general question is how can I (if it all in all is done this way) increase the load speed by compressing the file with <code>gzcompress</code>.</p>
  
  <p>The image of the files is below, and the code of files is as follows:</p>
  
  <p>_makeCache.php, in which I make the gzcompressed version of the plain.cache file:</p>
  
  <pre><code>$str = file_get_contents("plain.cache");
  $strCompressed = gzcompress($str, 9);
  
  $file = "gz.cache";
  $fp = fopen($file, "w");
  
  fwrite($fp, $strCompressed);
  fclose($fp);
  </code></pre>
  
  <p>plain.php:</p>
  
  <pre><code>echo file_get_contents("plain.cache");
  </code></pre>
  
  <p>gz.php:</p>
  
  <pre><code>echo gzuncompress(file_get_contents("plain.cache"));
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/EYJ7G.jpg" alt="enter image description here"></p>