3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $zipStr = 'UEsDBBQACAAIABprdEEAAAAAAAAAAAAAAAAWAAAAb2JqZWN0cy9Db250YWN0Lm9iamVjdI2SX0vDMBTF3/cpSt9NOhERyTJCl+Gga6VNBZ9GlmWuI21mk0799ka7P50TXR4C9+R3L5ecg4bvpfK2sjaFrgZ+HwS+JyuhF0X1MvBzNr6684e4h8LGWF0m87UU1nMtlRn4K2s39xAazTfALHUtJBC6hNdBcAuDG1hKyxfcch/3PHeQKox9KuSbaetvbdkoFfNSYqEry4WdpXxdzBE86EdUaNWUlcHjPIpmMZlSBPfSOUTCMMljBv7jwiRmJGSATVh0Efj4kMS0fwlJp2QS/Q2mFOQZTTNAognJfmOXhbKyzoTeSEydSx925Yxx/9PRf9Kd/p0q1eKwVphSwuhoNnL315yvt1Pezay5dXHAShqT1PS14QrBo3yKb7lqJGbJiDwj2BbHjeDZSkjxuVR7v72d363Y5gR2goJgN3i49wlQSwcI3kTEMT8BAACvAgAAUEsDBBQACAAIABprdEEAAAAAAAAAAAAAAAALAAAAcGFja2FnZS54bWxNj00LwjAMhu/7FaN3lzpkiHTdQfDkQUS9StbFWbXtWIsf/96xDzSX5CF53ySieJtH/KTWa2dzNk84i8kqV2lb5+x42MyWrJCR2KG6Y01xN219zq4hNCsA77BJ/MW1ihLlDKScZ8AXYChghQGZjOIuRPg05Ie6Z0Om7FbKtbMBVei0fT7v8aZLAVP7J7BoSG61DydNLwE9Dtbw5y3GP2SaJVzARJGA8XwZfQFQSwcIaf0pNKsAAADwAAAAUEsBAhQAFAAIAAgAGmt0Qd5ExDE/AQAArwIAABYAAAAAAAAAAAAAAAAAAAAAAG9iamVjdHMvQ29udGFjdC5vYmplY3RQSwECFAAUAAgACAAaa3RBaf0pNKsAAADwAAAACwAAAAAAAAAAAAAAAACDAQAAcGFja2FnZS54bWxQSwUGAAAAAAIAAgB9AAAAZwIAAAAA'; // Prepare Tmp File for Zip archive $file = tempnam("tmp", "zip"); $zip = new ZipArchive(); $zip->open($file, ZipArchive::OVERWRITE); // Add contents $zip->addFromString('your_file_name', base64_decode($zipStr)); // Close and send to users $zip->close(); header('Content-Type: application/zip'); header('Content-Length: ' . filesize($file)); header('Content-Disposition: attachment; filename="file.zip"'); readfile($file); unlink($file);
Output for 7.0.0 - 7.3.0rc4
Fatal error: Uncaught Error: Class 'ZipArchive' not found in /in/CND1X:7 Stack trace: #0 {main} thrown in /in/CND1X on line 7
Process exited with code 255.
Output for 5.4.10 - 5.6.28
Fatal error: Class 'ZipArchive' not found in /in/CND1X on line 7
Process exited with code 255.
Output for 5.3.29
PK���GsG�A��your_file_name �ffa�B��G$ �IY��%��y%��%z~�x��"G����k%(x��i���K}Y�MK]���6���7��s�c嘾?)ן>����O�6���c��g٧��P��чb�}�>��h?t,"V��V�kźS%hg��:k~@�TWE`W�u��f����w��۔O���z2;�u~�M ��AI �O��]Z{F��{H��)S>��J3����!���l�RISIi�(��c‘-����S���.y"�k찈�d]���M�ε����-_��������u�ц�A�^d�}�>g���{g��,-<�%5�ʗ��.���ߙ��v��F�����7�<>� �޿w�7���55%�W�����q�刡=#�z&��Q� ���ى�z�9���܇ x��]\>�*����'�.{����6�[�����&ӟ(V�WYT1�ϒk���f��'��3�����qfښ o,ܕ�[h�[{n���6� ��n�zʳdN����Vƙ=��\~�<iߕ��Mة��C_l��{�q�7c�o� y[��}�m��}x�{�>e�j��� k$kA~��i�� ?22�0 |��1t�=١��l>7��fF�p �fe 3a-�Ng�PK���GsG�A��your_file_namePK<�
Output for 5.3.28
PK���GsG�A��your_file_name �ffa�B��G$ �IY��%��y%��%z~�x��"G����k%(x��i���K}Y�MK]���6���7��s�c嘾?)ן>����O�6���c��g٧��P��чb�}�>��h?t,"V��V�kźS%hg��:k~@�TWE`W�u��f����w��۔O���z2;�u~�M ��AI �O��]Z{F��{H��)S>��J3����!���l�RISIi�(��c‘-����S���.y"�k찈�d]���M�ε����-_��������u�ц�A�^d�}�>g���{g��,-<�%5�ʗ��.���ߙ��v��F�����7�<>� �޿w�7���55%�W�����q�刡=#�z&��Q� ���ى�z�9���܇ x��]\>�*����'�.{����6�[�����&ӟ(V�WYT1�ϒk���f��'��3�����qfښ o,ܕ�[h�[{n���6� ��n�zʳdN����Vƙ=��\~�<iߕ��Mة��C_l��{�q�7c�o� y[��}�m��}x�{�>e�j��� k$kA~��i�� ?22�0 |��1t�=١��l>7��fF�p �fe 3a-�Ng�PK���GsG�A��your_file_namePK<�
Output for 5.3.22 - 5.3.27
PK���GsG�A��your_file_name �ffa�B��G$ �IY��%��y%��%z~�x��"G����k%(x��i���K}Y�MK]���6���7��s�c嘾?)ן>����O�6���c��g٧��P��чb�}�>��h?t,"V��V�kźS%hg��:k~@�TWE`W�u��f����w��۔O���z2;�u~�M ��AI �O��]Z{F��{H��)S>��J3����!���l�RISIi�(��c‘-����S���.y"�k찈�d]���M�ε����-_��������u�ц�A�^d�}�>g���{g��,-<�%5�ʗ��.���ߙ��v��F�����7�<>� �޿w�7���55%�W�����q�刡=#�z&��Q� ���ى�z�9���܇ x��]\>�*����'�.{����6�[�����&ӟ(V�WYT1�ϒk���f��'��3�����qfښ o,ܕ�[h�[{n���6� ��n�zʳdN����Vƙ=��\~�<iߕ��Mة��C_l��{�q�7c�o� y[��}�m��}x�{�>e�j��� k$kA~��i�� ?22�0 |��1t�=١��l>7��fF�p �fe 3a-�Ng�PK���GsG�A��your_file_namePK<�
Output for 5.3.20 - 5.3.21
PK���GsG�A��your_file_name �ffa�B��G$ �IY��%��y%��%z~�x��"G����k%(x��i���K}Y�MK]���6���7��s�c嘾?)ן>����O�6���c��g٧��P��чb�}�>��h?t,"V��V�kźS%hg��:k~@�TWE`W�u��f����w��۔O���z2;�u~�M ��AI �O��]Z{F��{H��)S>��J3����!���l�RISIi�(��c‘-����S���.y"�k찈�d]���M�ε����-_��������u�ц�A�^d�}�>g���{g��,-<�%5�ʗ��.���ߙ��v��F�����7�<>� �޿w�7���55%�W�����q�刡=#�z&��Q� ���ى�z�9���܇ x��]\>�*����'�.{����6�[�����&ӟ(V�WYT1�ϒk���f��'��3�����qfښ o,ܕ�[h�[{n���6� ��n�zʳdN����Vƙ=��\~�<iߕ��Mة��C_l��{�q�7c�o� y[��}�m��}x�{�>e�j��� k$kA~��i�� ?22�0 |��1t�=١��l>7��fF�p �fe 3a-�Ng�PK���GsG�A��your_file_namePK<�