note 130087 added to language.types
| From: | Anonymous | Date: | Fri, 28 Feb 2025 11:01:41 +0000 |
| Subject: | note 130087 added to language.types | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-221913@lists.php.net to get a copy of this message | ||
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Products</title>
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/css/bootstrap.min.css"
rel="stylesheet"
integrity="sha384-QWTKZyjpPEjISv5WaRU9OFeRpok6YctnYmDr5pNlyT2bRjXh0JMhjY6hW+ALEwIH"
crossorigin="anonymous">
</head>
<body>
<div class="container">
<!-- STEP 1: Ausgabe des Array -->
<?php
// echo "<pre>"; print_r($result); echo "</pre>";
?>
<!-- STEP 2: Ausgabe in einer HTML-Tabelle -->
<h1>Products</h1>
<table>
<thead>
<tr>
<?php
for ($i = 0; $i < 26; $i++) {
echo "<th><a href='?lett=" . chr(65 + $i) .
"'>" . chr(65 + $i) . "</a></th>";
}
?>
</tr>
</thead>
</table>
<form action="offices.php" method="GET">
<?php
echo "<input type='text' name='search' value='" .
$_SESSION['search'] . "'>";
?>
<input type="submit">
</form>
<form action="offices.php" method="GET">
<table class="table">
<thead>
<tr>
<th></th>
<?php
echo "<th><a href='?sort=officeCode'>Office
Code</a></th>";
echo "<th><a
href='?sort=city'>City</a></th>";
echo "<th><a
href='?sort=phone'>Phone</a></th>";
echo "<th><a href='?sort=addressLine1'>Address
1</a></th>";
echo "<th><a href='?sort=addressLine2'>Address
2</a></th>";
echo "<th><a
href='?sort=state'>State</a></th>";
echo "<th><a
href='?sort=country'>Country</a></th>";
echo "<th><a href='?sort=postalCode'>Postal
Code</a></th>";
echo "<th><a
href='?sort=territory'>Territory</a></th>";
?>
<th></th>
</tr>
</thead>
<tbody>
<?php
foreach ($result as $row) {
// Iteration über alle Datensätze -> Ergebnis ist ein 1-dimensionales
assoziatives Array
// print_r($result); // Ausgabe des Arrays zu Testzwecken
echo "<tr>";
// Werte in einer Table-row ausgeben
echo "<td><input type='checkbox' name='del[]'
value='" . $row['officeCode'] . "'></td>";
echo "<td>" . $row['officeCode'] . "</td>";
echo "<td>" . $row['city'] . "</td>";
echo "<td>" . $row['phone'] . "</td>";
echo "<td>" . $row['addressLine1'] . "</td>";
echo "<td>" . $row['addressLine2'] . "</td>";
echo "<td>" . $row['state'] . "</td>";
echo "<td>" . $row['country'] . "</td>";
echo "<td>" . $row['postalCode'] . "</td>";
echo "<td>" . $row['territory'] . "</td>";
echo "</tr>";
}
?>
</tbody>
</table>
<button type="submit">Delete Selected</button>
</form>
</div>
</body>
</html>
----
Server IP: 45.112.84.4
Probable Submitter: 80.90.5.137 (proxied: 193.170.70.27)
----
Manual Page -- https://php.net/manual/en/language.types.php
Edit -- https://main.php.net/note/edit/130087
Del: integrated -- https://main.php.net/note/delete/130087/integrated
Del: useless -- https://main.php.net/note/delete/130087/useless
Del: bad code -- https://main.php.net/note/delete/130087/bad+code
Del: spam -- https://main.php.net/note/delete/130087/spam
Del: non-english -- https://main.php.net/note/delete/130087/non-english
Del: in docs -- https://main.php.net/note/delete/130087/in+docs
Del: other reasons-- https://main.php.net/note/delete/130087
Reject -- https://main.php.net/note/reject/130087
Search -- https://main.php.net/manage/user-notes.php