3v4l.org

run code in 300+ PHP versions simultaneously
<?php $texthtml = '<p>test</p><br><p><img src="1.jpeg" alt=""><br></p><p><img src="2.png" alt=""><br><img src="3.png" alt=""></p>'; $search = 'img src="'; $pos = strpos($texthtml, $search)+ strlen($search); $lenght= strpos($texthtml, '"', $pos)-$pos; echo substr($texthtml, $pos, $lenght);

This is an error 500

Value for `_results` contains invalid data `array`


preferences:
165.5 ms | 2575 KiB | 12 Q