3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $titles_array = array("asdf","xcv","","123"); $subject = "sd"; print_r($title_array); foreach($titles_array as $k=>$v) { if(strpos($subject,$v) !== false) { $i++; $asd[$titles['id']] = $i; } }
Output for 5.3.22 - 5.3.29, 5.4.12 - 7.1.0
Notice: Undefined variable: title_array in /in/qABCm on line 4 Warning: strpos(): Empty needle in /in/qABCm on line 6
Output for 5.2.5 - 5.3.21, 5.4.0 - 5.4.11
Notice: Undefined variable: title_array in /in/qABCm on line 4 Warning: strpos(): Empty delimiter in /in/qABCm on line 6
Output for 5.0.4 - 5.2.4
Notice: Undefined variable: title_array in /in/qABCm on line 4 Warning: strpos(): Empty delimiter. in /in/qABCm on line 6
Output for 4.3.2 - 5.0.3
Notice: Undefined variable: title_array in /in/qABCm on line 4 Warning: strpos(): Empty delimiter. in /in/qABCm on line 6
Output for 4.3.0 - 4.3.1
Notice: Undefined variable: title_array in /in/qABCm on line 4 Warning: strpos() [http://www.php.net/function.strpos]: Empty delimiter. in /in/qABCm on line 6