3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $string = '<p>Lorem ipsum dolor sitamet consec tetuer adipiscing elit praesent ves tibulum moles tie lacusenean non ummy hendrer maur hasellus porta usce suscipit varius mi.</p> <p><!-- pagebreak --></p> <p>Lorem ipsum next.</p>'; $string = substr($string, 0, strpos($string, '<!-- pagebreak -->')); var_dump($string);

Shows result from various feature-branches currently under review from the php developers. Contact me to have additional branches featured.

Output for Typed properties v2
string(170) "<p>Lorem ipsum dolor sitamet consec tetuer adipiscing elit praesent ves tibulum moles tie lacusenean non ummy hendrer maur hasellus porta usce suscipit varius mi.</p> <p>"
Output for Arrow functions
string(170) "<p>Lorem ipsum dolor sitamet consec tetuer adipiscing elit praesent ves tibulum moles tie lacusenean non ummy hendrer maur hasellus porta usce suscipit varius mi.</p> <p>"
Output for Object typehint
string(170) "<p>Lorem ipsum dolor sitamet consec tetuer adipiscing elit praesent ves tibulum moles tie lacusenean non ummy hendrer maur hasellus porta usce suscipit varius mi.</p> <p>"
Output for Array change keys
string(170) "<p>Lorem ipsum dolor sitamet consec tetuer adipiscing elit praesent ves tibulum moles tie lacusenean non ummy hendrer maur hasellus porta usce suscipit varius mi.</p> <p>"
Output for Lexical anon
string(170) "<p>Lorem ipsum dolor sitamet consec tetuer adipiscing elit praesent ves tibulum moles tie lacusenean non ummy hendrer maur hasellus porta usce suscipit varius mi.</p> <p>"

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