moved appreciations array to recipe view before calling appreciations view
This commit is contained in:
parent
ac1e9bd677
commit
24afac65b6
@ -1,37 +1,3 @@
|
||||
<?php
|
||||
$appreciations = array(
|
||||
array(
|
||||
"NAME" => "test",
|
||||
"PROFILE_IMG" => "1.jpg",
|
||||
"COMMENT" => "j'me présente, je m'appelle henry",
|
||||
"NOTE" => "2",
|
||||
"DATE" => DATE("2020-07-08")
|
||||
),
|
||||
array(
|
||||
"NAME" => "test",
|
||||
"PROFILE_IMG" => "1.jpg",
|
||||
"COMMENT" => "j'me présente, je m'appelle henry",
|
||||
"NOTE" => "2",
|
||||
"DATE" => DATE("2020-07-08")
|
||||
),
|
||||
array(
|
||||
"NAME" => "test",
|
||||
"PROFILE_IMG" => "1.jpg",
|
||||
"COMMENT" => "j'me présente, je m'appelle henry",
|
||||
"NOTE" => "2",
|
||||
"DATE" => DATE("2020-07-08")
|
||||
),
|
||||
array(
|
||||
"NAME" => "AAAA",
|
||||
"PROFILE_IMG" => "/static/img/recipes/1.jpg",
|
||||
"COMMENT" => "j'me présente, je m'appelle henry",
|
||||
"NOTE" => "2",
|
||||
"DATE" => DATE("2020-07-08")
|
||||
),
|
||||
);
|
||||
?>
|
||||
|
||||
|
||||
<section>
|
||||
<h1> Appréciations: </h1>
|
||||
<form method="POST" action="/">
|
||||
@ -50,8 +16,8 @@ $appreciations = array(
|
||||
</form>
|
||||
|
||||
<?php
|
||||
foreach ($appreciations as $appreciation){
|
||||
foreach ($A_view as $appreciation){
|
||||
View::show("appreciations/appreciation", $appreciation);
|
||||
}
|
||||
?>
|
||||
</section>
|
||||
</section>
|
||||
|
@ -35,7 +35,37 @@
|
||||
<p>By <?= $A_view["AUTHOR_USERNAME"] ?></p>
|
||||
|
||||
<?php
|
||||
View::show("appreciations/view")//need to be linked with recipe?
|
||||
$appreciations = array(
|
||||
array(
|
||||
"NAME" => "test",
|
||||
"PROFILE_IMG" => "/static/img/users/1.jpg",
|
||||
"COMMENT" => "j'me présente, je m'appelle henry",
|
||||
"NOTE" => "2",
|
||||
"DATE" => DATE("2020-07-08")
|
||||
),
|
||||
array(
|
||||
"NAME" => "test",
|
||||
"PROFILE_IMG" => "/static/img/users/1.jpg",
|
||||
"COMMENT" => "j'me présente, je m'appelle henry",
|
||||
"NOTE" => "2",
|
||||
"DATE" => DATE("2020-07-08")
|
||||
),
|
||||
array(
|
||||
"NAME" => "test",
|
||||
"PROFILE_IMG" => "/static/img/users/1.jpg",
|
||||
"COMMENT" => "j'me présente, je m'appelle henry",
|
||||
"NOTE" => "2",
|
||||
"DATE" => DATE("2020-07-08")
|
||||
),
|
||||
array(
|
||||
"NAME" => "AAAA",
|
||||
"PROFILE_IMG" => "/static/img/users/1.jpg",
|
||||
"COMMENT" => "j'me présente, je m'appelle henry",
|
||||
"NOTE" => "2",
|
||||
"DATE" => DATE("2020-07-08")
|
||||
),
|
||||
);
|
||||
View::show("appreciations/view", $appreciations)//need to be linked with recipe?
|
||||
?>
|
||||
|
||||
</main>
|
||||
|
Loading…
Reference in New Issue
Block a user