3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $string = '<p>Lorem ipsum dolor sitamet</p> <p><!-- pagebreak --></p> <p>Lorem ipsum next.</p>'; $string = substr($string, 0, strpos($string, '<!-- pagebreak -->')); var_dump($string);
Output for 4.3.0 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
string(36) "<p>Lorem ipsum dolor sitamet</p> <p>"