3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<!Doctype HTML> <html lang="pt-br"> <head> <title> Repetição em PHP </title> </head> <body> <?php $arrayGames = array("Watch_Dogs " => " R$199,90", "Dead Space " => " R$149,90", "Wolfenstein " => " R$189,90"); foreach($arrayGames as $titulo => $preco){ echo"<p>Jogo: " . $titulo . "<img src='img/watch_dogs.jpg' /> </p>" . $preco; } ?> </body> </html>
Output for 4.3.0 - 7.1.0
<!Doctype HTML> <html lang="pt-br"> <head> <title> Repetição em PHP </title> </head> <body> <p>Jogo: Watch_Dogs <img src='img/watch_dogs.jpg' /> </p> R$199,90<p>Jogo: Dead Space <img src='img/watch_dogs.jpg' /> </p> R$149,90<p>Jogo: Wolfenstein <img src='img/watch_dogs.jpg' /> </p> R$189,90</body> </html>