mirror of
https://github.com/FlyInTheBox/31TSAI.git
synced 2024-11-09 20:44:11 +01:00
l
This commit is contained in:
parent
3ea3ed4b19
commit
7a8b55262c
1 changed files with 52 additions and 0 deletions
52
Zadanie 14.12.2022/index.php
Normal file
52
Zadanie 14.12.2022/index.php
Normal file
|
@ -0,0 +1,52 @@
|
|||
<!doctype html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport"
|
||||
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
|
||||
<meta http-equiv="X-UA-Compatible" content="ie=edge">
|
||||
<title>Tabliczka mnożenia</title>
|
||||
<style>
|
||||
table {
|
||||
border: 1px solid black;
|
||||
font-family: Verdana;
|
||||
font-size: large;
|
||||
border-collapse: collapse;
|
||||
}
|
||||
|
||||
th {
|
||||
background-color: burlywood;
|
||||
border: 1px dotted black;
|
||||
padding: 5px;
|
||||
}
|
||||
|
||||
td {
|
||||
border: 1px dotted black;
|
||||
padding: 5px;
|
||||
text-align: center;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<table>
|
||||
<th>X</th>
|
||||
<?PHP
|
||||
for ($col = 1; $col <= 100; $col++) {
|
||||
echo '<th>' . $col . '</th>';
|
||||
}
|
||||
for ($col = 1; $col <= 100; $col++) {
|
||||
echo '<tr><th>' . $col . '</th>';
|
||||
for ($row = 1; $row <= 100; $row++) {
|
||||
if ($col != $row) {
|
||||
echo '<td style="background-color: beige">' . ($col * $row) . '</td>';
|
||||
} else {
|
||||
echo '<td style="background-color: bisque;">' . ($col * $row) . '</td>';
|
||||
}
|
||||
}
|
||||
echo '</tr>';
|
||||
}
|
||||
echo '</tr>';
|
||||
?>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
Loading…
Reference in a new issue