Community I am with the following problem: I would like to print images randomly (array created in PHP) every X seconds in a script with setTimeout. The function is as follows:
<?php $pic = array('image_1.jpg','image_2.jpg','image_3.jpg');
shuffle($pic); ?>
<?php for($i = 0, $i < 1, $i++) echo "<li style=\"display: flex;\"><img src=\"$pic[$i]\" width=\"250\" height=\"250\"></li>"; ?>
Based on this, how do I do it? Thank you
this is my suggestion: