3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $string1 = '05% off'. '<br/>'; $string2 = '03% Off'. '<br/>'; $string3 = '50% OFF'. '<br/>'; $string4 = '50% oFf'. '<br/>'; $firstsub = substr( $string1, 4 ); $secondsub = substr( $string2, 4 ); $threesub = substr( $string3, 4 ); $foursub = substr( $string3, 4 ); var_dump($firstsub, $secondsub, $threesub, $foursub); ?>
Output for 4.3.0 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
string(8) "off<br/>" string(8) "Off<br/>" string(8) "OFF<br/>" string(8) "OFF<br/>"