3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $header = array('Set-Cookie: A tua tia', 'Set-Cookie:Test','Set-cookie:atuatia','xptoset-cookie'); foreach($header as $line) { if(stripos($line, 'Set-Cookie:') === 0) { $line = trim(str_ireplace('Set-Cookie:', '', $line)); } echo $line.PHP_EOL; } ?>
Output for 5.0.2 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
A tua tia Test atuatia xptoset-cookie
Output for 5.0.0 - 5.0.1
Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/S72Sj on line 8 A tua tiaPHP_EOL Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/S72Sj on line 8 TestPHP_EOL Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/S72Sj on line 8 atuatiaPHP_EOL Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/S72Sj on line 8 xptoset-cookiePHP_EOL
Output for 4.4.5 - 4.4.9
Fatal error: Call to undefined function: stripos() in /in/S72Sj on line 5
Process exited with code 255.
Output for 4.3.2 - 4.4.4
Fatal error: Call to undefined function: stripos() in /in/S72Sj on line 5
Process exited with code 255.
Output for 4.3.0 - 4.3.1
Fatal error: Call to undefined function: stripos() in /in/S72Sj on line 5