Part on Page Links in Section2 finished.
This commit is contained in:
parent
9e01258040
commit
7aa8e6f047
8 changed files with 622 additions and 35 deletions
23
index.php
23
index.php
|
|
@ -1,25 +1,2 @@
|
|||
<?php
|
||||
$books = [
|
||||
[
|
||||
'name' => 'Do Androids Dream of Electric Sheep',
|
||||
'author' => 'Philip K. Dick',
|
||||
'releaseYear' => 1968,
|
||||
'purchaseUrl' =>'http://example.com'
|
||||
],
|
||||
[
|
||||
'name' => 'Projekt Hail Mary',
|
||||
'author' => 'Andy Weir',
|
||||
'releaseYear' => 2021,
|
||||
'purchaseUrl' => 'http://example.com'
|
||||
],
|
||||
[
|
||||
'name' => 'The Martian',
|
||||
'author' => 'Andy Weir',
|
||||
'releaseYear' => 2011,
|
||||
'purchaseUrl' => 'http://example.com'
|
||||
]
|
||||
];
|
||||
$filteredItems = array_filter($books, function($book) {
|
||||
return $book['author'] == 'Andy Weir';
|
||||
});
|
||||
require "index.view.php";
|
||||
Loading…
Add table
Add a link
Reference in a new issue