3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $data = "Lorem ipsum shizzle ma nizle"; echo "\n\n\n"; echo (((gzcompress($data,strlen($data))))) . PHP_EOL . PHP_EOL; echo "\n\n\n"; echo (((gzdeflate($data,strlen($data))))) . PHP_EOL . PHP_EOL; echo "\n\n\n"; echo (((gzencode($data,strlen($data),FORCE_GZIP)))) . PHP_EOL . PHP_EOL; echo "\n\n\n"; echo (((gzencode($data,strlen($data),FORCE_DEFLATE)))) . PHP_EOL . PHP_EOL; echo "\n\n\n";
based on 3Q8fi
Output for 5.4.0 - 5.6.30, 7.0.0 - 7.3.0rc4
Warning: gzcompress(): compression level (28) must be within -1..9 in /in/HIvbn on line 5 Warning: gzdeflate(): compression level (28) must be within -1..9 in /in/HIvbn on line 7 Warning: gzencode(): compression level (28) must be within -1..9 in /in/HIvbn on line 9 Warning: gzencode(): compression level (28) must be within -1..9 in /in/HIvbn on line 11
Output for hhvm-3.10.1 - 3.17.3
Warning: compression level (28) must be within -1..9 in /in/HIvbn on line 5 Warning: compression level (28) must be within -1..9 in /in/HIvbn on line 7 Warning: compression level (28) must be within -1..9 in /in/HIvbn on line 9 Warning: compression level (28) must be within -1..9 in /in/HIvbn on line 11
Output for 5.0.2 - 5.3.29
Warning: gzcompress(): compression level (28) must be within -1..9 in /in/HIvbn on line 5 Warning: gzdeflate(): compression level (28) must be within -1..9 in /in/HIvbn on line 7 Warning: gzencode(): compression level(28) must be within -1..9 in /in/HIvbn on line 9 Warning: gzencode(): compression level(28) must be within -1..9 in /in/HIvbn on line 11
Output for 5.0.0 - 5.0.1
Warning: gzcompress(): compression level (28) must be within -1..9 in /in/HIvbn on line 5 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 5 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 5 PHP_EOLPHP_EOL Warning: gzdeflate(): compression level (28) must be within -1..9 in /in/HIvbn on line 7 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 7 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 7 PHP_EOLPHP_EOL Warning: gzencode(): compression level(28) must be within -1..9 in /in/HIvbn on line 9 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 9 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 9 PHP_EOLPHP_EOL Warning: gzencode(): compression level(28) must be within -1..9 in /in/HIvbn on line 11 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 11 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 11 PHP_EOLPHP_EOL
Output for 4.3.10 - 4.4.9
Warning: gzcompress(): compression level(28) must be within 0..9 in /in/HIvbn on line 5 Warning: gzdeflate(): compression level(28) must be within 0..9 in /in/HIvbn on line 7 Warning: gzencode(): compression level(28) must be within -1..9 in /in/HIvbn on line 9 Warning: gzencode(): compression level(28) must be within -1..9 in /in/HIvbn on line 11
Output for 4.3.2 - 4.3.9
Warning: gzcompress(): compression level(28) must be within 0..9 in /in/HIvbn on line 5 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 5 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 5 PHP_EOLPHP_EOL Warning: gzdeflate(): compression level(28) must be within 0..9 in /in/HIvbn on line 7 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 7 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 7 PHP_EOLPHP_EOL Warning: gzencode(): compression level(28) must be within -1..9 in /in/HIvbn on line 9 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 9 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 9 PHP_EOLPHP_EOL Warning: gzencode(): compression level(28) must be within -1..9 in /in/HIvbn on line 11 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 11 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 11 PHP_EOLPHP_EOL
Output for 4.3.0 - 4.3.1
Warning: gzcompress() [http://www.php.net/function.gzcompress]: compression level(28) must be within 0..9 in /in/HIvbn on line 5 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 5 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 5 PHP_EOLPHP_EOL Warning: gzdeflate() [http://www.php.net/function.gzdeflate]: compression level(28) must be within 0..9 in /in/HIvbn on line 7 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 7 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 7 PHP_EOLPHP_EOL Warning: gzencode() [http://www.php.net/function.gzencode]: compression level(28) must be within -1..9 in /in/HIvbn on line 9 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 9 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 9 PHP_EOLPHP_EOL Warning: gzencode() [http://www.php.net/function.gzencode]: compression level(28) must be within -1..9 in /in/HIvbn on line 11 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 11 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/HIvbn on line 11 PHP_EOLPHP_EOL