3v4l.org

run code in 200+ PHP versions simultaneously
<?php function example(){ ?> <h1>Text</h1> <?php } example();
Output for 4.3.0 - 7.4.1
<h1>Text</h1>