質問編集履歴
2
キャプチャ
test
CHANGED
File without changes
|
test
CHANGED
@@ -122,3 +122,7 @@
|
|
122
122
|
![イメージ説明](https://ddjkaamml8q8x.cloudfront.net/questions/2022-06-10/a2d3c532-3554-414b-a6f4-42bd7d81c52c.png)
|
123
123
|
|
124
124
|
![イメージ説明](https://ddjkaamml8q8x.cloudfront.net/questions/2022-06-10/5a1904e0-a9ed-45e2-b0f7-03d452ce7ee1.png)
|
125
|
+
|
126
|
+
![イメージ説明](https://ddjkaamml8q8x.cloudfront.net/questions/2022-06-11/be6218f1-e812-49e0-9574-6f2eb7dd9c24.png)
|
127
|
+
|
128
|
+
![イメージ説明](https://ddjkaamml8q8x.cloudfront.net/questions/2022-06-11/be1894ac-dfb1-4f80-a519-f50c238ff023.png)
|
1
キャプチャの更新
test
CHANGED
File without changes
|
test
CHANGED
@@ -118,91 +118,7 @@
|
|
118
118
|
// MySQLを使った処理が終わると、接続は不要なので切断する
|
119
119
|
mysqli_close($database);
|
120
120
|
?>
|
121
|
-
<!DOCTYPE html>
|
122
|
-
<html lang="ja">
|
123
|
-
<head>
|
124
|
-
<meta charset="utf-8">
|
125
|
-
<title>Bookshelf | カンタン!あなたのオンライン本棚</title>
|
126
|
-
<link rel="stylesheet" href="bookshelf.css">
|
127
|
-
</head>
|
128
|
-
<body>
|
129
|
-
<header>
|
130
|
-
<div id="header">
|
131
|
-
<div id="logo">
|
132
|
-
<a href="./bookshelf_index.php"><img src="./images/logo.png" alt="Bookshelf"></a>
|
133
|
-
</div>
|
134
|
-
<nav>
|
135
|
-
<a href="./bookshelf_form.php"><img src="./images/icon_plus.png" alt=""> 書籍登録</a>
|
136
|
-
</nav>
|
137
|
-
</div>
|
138
|
-
</header>
|
139
|
-
<div id="cover">
|
140
|
-
<h1 id="cover_title">カンタン!あなたのオンライン本棚</h1>
|
141
|
-
<form action="bookshelf_index.php" method="post">
|
142
|
-
<div class="book_status unread active">
|
143
|
-
<input type="submit" name="submit_only_unread" value="未読"><br>
|
144
|
-
<div class="book_count"><?php print h($count_unread); ?></div>
|
145
|
-
</div>
|
146
|
-
<div class="book_status reading active">
|
147
|
-
<input type="submit" name="submit_only_reading" value="読中"><br>
|
148
|
-
<div class="book_count"><?php print h($count_reading); ?></div>
|
149
|
-
</div>
|
150
|
-
<div class="book_status finished active">
|
151
|
-
<input type="submit" name="submit_only_finished" value="読了"><br>
|
152
|
-
<div class="book_count"><?php print h($count_finished); ?></div>
|
153
|
-
</div>
|
154
|
-
<div class="book_status hold active">
|
155
|
-
<input type="submit" name="submit_only_hold" value="保留"><br>
|
156
|
-
<div class="book_count"><?php print h($count_hold); ?></div>
|
157
|
-
</div>
|
158
|
-
</form>
|
159
|
-
</div>
|
160
|
-
<div class="wrapper">
|
161
|
-
<div id="main">
|
162
|
-
<div id="book_list">
|
163
|
-
<?php
|
164
|
-
if ($result) {
|
165
|
-
while ($record = mysqli_fetch_assoc($result)) {
|
166
|
-
// 1レコード分の値をそれぞれ変数に代入する
|
167
|
-
$id = $record['id'];
|
168
|
-
$title = $record['title'];
|
169
|
-
$image_url = $record['image_url'];
|
170
|
-
$status = $record['status'];
|
171
|
-
$created_at = $record['created_at'];
|
172
|
-
?>
|
173
|
-
<div class="book_item">
|
174
|
-
<div class="book_image">
|
175
|
-
<img src="<?php print h($image_url); ?>" alt="">
|
176
|
-
</div>
|
177
|
-
<div class="book_detail">
|
178
|
-
<div class="book_title">
|
179
|
-
<?php print h($title); ?>
|
180
|
-
</div>
|
181
|
-
<div class="book_date">
|
182
|
-
<?php print h($created_at); ?>
|
183
|
-
</div>
|
184
|
-
<form action="bookshelf_index.php" method="post">
|
185
|
-
<input type="hidden" name="book_id" value="<?php print h($id); ?>">
|
186
|
-
<div class="book_status unread <?php if ($status == "unread") print "active"; ?>">
|
187
|
-
<input type="submit" name="submit_book_unread" value="未読">
|
188
|
-
</div>
|
189
|
-
<div class="book_status reading <?php if ($status == "reading") print "active"; ?>">
|
190
|
-
<input type="submit" name="submit_book_reading" value="読中">
|
191
|
-
</div>
|
192
|
-
<div class="book_status finished <?php if ($status == "finished") print "active"; ?>">
|
193
|
-
<input type="submit" name="submit_book_finished" value="読了">
|
194
|
-
</div>
|
195
|
-
<div class="book_status hold <?php if ($status == "hold") print "active"; ?>">
|
196
|
-
<input type="submit" name="submit_book_hold" value="保留">
|
197
|
-
</div>
|
198
|
-
</form>
|
199
|
-
|
200
|
-
===省略
|
201
121
|
|
202
|
-
<footer>
|
203
|
-
|
122
|
+
![イメージ説明](https://ddjkaamml8q8x.cloudfront.net/questions/2022-06-10/a2d3c532-3554-414b-a6f4-42bd7d81c52c.png)
|
123
|
+
|
204
|
-
|
124
|
+
![イメージ説明](https://ddjkaamml8q8x.cloudfront.net/questions/2022-06-10/5a1904e0-a9ed-45e2-b0f7-03d452ce7ee1.png)
|
205
|
-
</body>
|
206
|
-
</html>
|
207
|
-
|
208
|
-
|