3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $stars = array('Tom' => 0.9, 'Dan' => 0.8, 'Max' => 0.1); arsort($stars); foreach ($stars as $name => $stars) { ?> <div style="font-size: 26pt;"><span style="width: 150px;"><?php echo htmlentities($name); ?></span> <?php echo str_repeat('<img style="height:30px;" src="http://ratherthecouch.files.wordpress.com/2013/02/gold-star.jpg?w=750" />', floor($stars / 5)); echo str_repeat('<img style="height:30px;" src="https://pbs.twimg.com/profile_images/446819911349043200/Q4Xvo_p5.jpeg" />', floor($stars % 5)); echo str_repeat('<img style="height:30px;" src="http://www.stalkingtools.com/img/logo.png" />', ( fmod($stars, 1) * 10)); ?> </div> <?php }
Output for 4.3.0 - 5.6.28, hhvm-3.12.0, 7.0.0 - 7.1.0
<div style="font-size: 26pt;"><span style="width: 150px;">Tom</span> <img style="height:30px;" src="http://www.stalkingtools.com/img/logo.png" /><img style="height:30px;" src="http://www.stalkingtools.com/img/logo.png" /><img style="height:30px;" src="http://www.stalkingtools.com/img/logo.png" /><img style="height:30px;" src="http://www.stalkingtools.com/img/logo.png" /><img style="height:30px;" src="http://www.stalkingtools.com/img/logo.png" /><img style="height:30px;" src="http://www.stalkingtools.com/img/logo.png" /><img style="height:30px;" src="http://www.stalkingtools.com/img/logo.png" /><img style="height:30px;" src="http://www.stalkingtools.com/img/logo.png" /><img style="height:30px;" src="http://www.stalkingtools.com/img/logo.png" /></div> <div style="font-size: 26pt;"><span style="width: 150px;">Dan</span> <img style="height:30px;" src="http://www.stalkingtools.com/img/logo.png" /><img style="height:30px;" src="http://www.stalkingtools.com/img/logo.png" /><img style="height:30px;" src="http://www.stalkingtools.com/img/logo.png" /><img style="height:30px;" src="http://www.stalkingtools.com/img/logo.png" /><img style="height:30px;" src="http://www.stalkingtools.com/img/logo.png" /><img style="height:30px;" src="http://www.stalkingtools.com/img/logo.png" /><img style="height:30px;" src="http://www.stalkingtools.com/img/logo.png" /><img style="height:30px;" src="http://www.stalkingtools.com/img/logo.png" /></div> <div style="font-size: 26pt;"><span style="width: 150px;">Max</span> <img style="height:30px;" src="http://www.stalkingtools.com/img/logo.png" /></div>
Output for hhvm-3.10.0

Process exited with code 153.