3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $r = '<div class="form-group>'; $label = '<label class="control-label" for="id_f-variants-99999-is_active">Is active</label>'; $label = substr($r, 0, strpos($r, ">")); $labe .= '>'; $r .= $label; $r .= '<input id="id_f-variants-99999-is_active" class="form-control checkbox" type="checkbox" name="f-variants-99999-is_active"></input>'; $r .= '<span class="unchecked">hoa</span>'; $r .= '<span class="checked">hoahoahoa</span>'; $r .= '</label>'; $r .= '</div>'; echo($r);
Output for 5.0.4 - 5.6.28, 7.0.0 - 7.1.0
Notice: Undefined variable: labe in /in/e5eor on line 5 <div class="form-group><div class="form-group<input id="id_f-variants-99999-is_active" class="form-control checkbox" type="checkbox" name="f-variants-99999-is_active"></input><span class="unchecked">hoa</span><span class="checked">hoahoahoa</span></label></div>
Output for hhvm-3.10.0 - 3.12.0
<div class="form-group><div class="form-group<input id="id_f-variants-99999-is_active" class="form-control checkbox" type="checkbox" name="f-variants-99999-is_active"></input><span class="unchecked">hoa</span><span class="checked">hoahoahoa</span></label></div>
Output for 4.3.0 - 5.0.3
Notice: Undefined variable: labe in /in/e5eor on line 5 <div class="form-group><div class="form-group<input id="id_f-variants-99999-is_active" class="form-control checkbox" type="checkbox" name="f-variants-99999-is_active"></input><span class="unchecked">hoa</span><span class="checked">hoahoahoa</span></label></div>