3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php while(strlen($sms) > 160) { echo "Here"; $short = substr($sms,0,159); echo "Send SMS Long"; $sms = str_replace($short,'',$sms); } if(strlen($sms) > 0) { echo "Send SMS Short"; } ?>
Output for 5.0.4 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
Notice: Undefined variable: sms in /in/8MUkG on line 3 Notice: Undefined variable: sms in /in/8MUkG on line 10
Output for 4.3.0 - 5.0.3
Notice: Undefined variable: sms in /in/8MUkG on line 3 Notice: Undefined variable: sms in /in/8MUkG on line 10