3v4l.org

run code in 300+ PHP versions simultaneously
<?php $prg = file_get_contents(implode('/',[$_SERVER['DOCUMENT_ROOT'],'../miser-vars/PRG/MISER.BAS'])); $Pattern=file_get_contents(implode('/',[$_SERVER['DOCUMENT_ROOT'],'../miser-vars/regex/LINES.re'])); $pagedata=file_get_contents(implode('/',[$_SERVER['DOCUMENT_ROOT'],'../miser-vars/html/index.html'])); $PRG2=''; $PRG2.= '<table><tbody>'; while(true) { while(true) { if(strlen($prg)===0){break 1;} preg_match($Pattern,$prg,$matches); file_put_contents ( implode ( '/', [ $_SERVER['DOCUMENT_ROOT'], '../miser-vars/PRG/'. $matches['linelabel'].'.BAS' ] ),$matches['linelabel'].$matches['sep'].$matches['code'] ); $prg=str_replace($matches['linelabel'].$matches['sep'].$matches['code'],'',$prg); $PRG2.= '<tr><td>PRG['.htmlentities($matches['linelabel']).']</td></tr><tr></td>'.htmlentities($matches['code']).'</td></tr>'; } } $PRG2.= '</tbody></table>'; $pagedata=str_replace('{{ title }}','Miser Ripper',$pagedata); $pagedata=str_replace('<< page >>',$PRG2,$pagedata); echo $pagedata; exit;
Output for 8.0.1 - 8.0.30, 8.1.0 - 8.1.28, 8.2.0 - 8.2.18, 8.3.0 - 8.3.6
Warning: file_get_contents(): open_basedir restriction in effect. File(/../miser-vars/PRG/MISER.BAS) is not within the allowed path(s): (/tmp:/in:/etc) in /in/nkVLD on line 3 Warning: file_get_contents(/../miser-vars/PRG/MISER.BAS): Failed to open stream: Operation not permitted in /in/nkVLD on line 3 Warning: file_get_contents(): open_basedir restriction in effect. File(/../miser-vars/regex/LINES.re) is not within the allowed path(s): (/tmp:/in:/etc) in /in/nkVLD on line 5 Warning: file_get_contents(/../miser-vars/regex/LINES.re): Failed to open stream: Operation not permitted in /in/nkVLD on line 5 Warning: file_get_contents(): open_basedir restriction in effect. File(/../miser-vars/html/index.html) is not within the allowed path(s): (/tmp:/in:/etc) in /in/nkVLD on line 7 Warning: file_get_contents(/../miser-vars/html/index.html): Failed to open stream: Operation not permitted in /in/nkVLD on line 7
Process exited with code 137.

preferences:
119 ms | 403 KiB | 89 Q