3v4l.org

run code in 300+ PHP versions simultaneously
<!DOCTYPE html> <html> <head> <meta charset=utf-8 /> <title>JS Bin</title> <style type="text/css"> table.tb {border-collapse:collapse; width:100%; margin:0px 20px;} table.tb td {border:1px solid red; width:3%;} table.tb th {text-align:left; color:blue; } th span {margin-left:-20px;}; td input[type=checkbox]:checked + span {color:green;} </style> </head> <body> <?php error_reporting(0); $numRow=3; $numCol=18; $i=$j=1; echo "<table class=\"tb\">"; while($i<=$numRow) { echo "<tr>"; if ($i==1) { while($j<=$numCol) { $tIncrement=30*($j-1); $time=date("H:i",strtotime("08:00+ $tIncrement minute")); echo "<th><span>$time</span></th>"; $j++; } } else { while($j<=$numCol) { echo "<td><input type=\"checkbox\" name=\"slot\" ><span>slot</span></td>"; $j++; } } $j=1; echo "</tr>"; $i++; } echo "</table>"; ?> </body> </html>
Output for git.master, git.master_jit, rfc.property-hooks
<!DOCTYPE html> <html> <head> <meta charset=utf-8 /> <title>JS Bin</title> <style type="text/css"> table.tb {border-collapse:collapse; width:100%; margin:0px 20px;} table.tb td {border:1px solid red; width:3%;} table.tb th {text-align:left; color:blue; } th span {margin-left:-20px;}; td input[type=checkbox]:checked + span {color:green;} </style> </head> <body> <table class="tb"><tr><th><span>08:00</span></th><th><span>08:30</span></th><th><span>09:00</span></th><th><span>09:30</span></th><th><span>10:00</span></th><th><span>10:30</span></th><th><span>11:00</span></th><th><span>11:30</span></th><th><span>12:00</span></th><th><span>12:30</span></th><th><span>13:00</span></th><th><span>13:30</span></th><th><span>14:00</span></th><th><span>14:30</span></th><th><span>15:00</span></th><th><span>15:30</span></th><th><span>16:00</span></th><th><span>16:30</span></th></tr><tr><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td></tr><tr><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td><td><input type="checkbox" name="slot" ><span>slot</span></td></tr></table></body> </html>

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
49.8 ms | 409 KiB | 8 Q