1
0
mirror of https://github.com/Daichimarukana/uwuzu.git synced 2026-06-05 11:34:41 +00:00

uwuzu v1.3.0 new_planet

This commit is contained in:
Daichimarukana
2024-02-24 19:17:08 +09:00
parent 29c46fcc4e
commit 1597041471
115 changed files with 5655 additions and 2252 deletions
+7 -2
View File
@@ -47,11 +47,12 @@ if (isset($_GET['userid']) && isset($_GET['account_id'])) {
$uwuzuid = htmlentities(isset($_GET['id'])) ? htmlentities($_GET['id']) : '';
$userid = htmlentities($_GET['userid']);
$aduserinfoQuery = $pdo->prepare("SELECT username,userid,loginid,admin,role,sacinfo,blocklist FROM account WHERE userid = :userid");
$aduserinfoQuery = $pdo->prepare("SELECT username,userid,loginid,admin,role,sacinfo,blocklist,bookmark FROM account WHERE userid = :userid");
$aduserinfoQuery->bindValue(':userid', htmlentities($userid));
$aduserinfoQuery->execute();
$res = $aduserinfoQuery->fetch();
$myblocklist = htmlentities($res["blocklist"]);
$mybookmark = htmlentities($res["bookmark"]);
$itemsPerPage = 15; // 1ページあたりのユーズ数
$pageNumber = htmlentities(isset($_GET['page'])) ? htmlentities(intval($_GET['page'])) : 1;
@@ -78,9 +79,11 @@ if (isset($_GET['userid']) && isset($_GET['account_id'])) {
(photo3 IS NOT NULL AND photo3 != '' AND photo3 != 'none') OR
(photo4 IS NOT NULL AND photo4 != '' AND photo4 != 'none') OR
(video1 IS NOT NULL AND video1 != '' AND video1 != 'none')
) ORDER BY datetime DESC LIMIT $offset, $itemsPerPage");
) ORDER BY datetime DESC LIMIT :offset, :itemsPerPage");
$messageQuery->bindValue(':userid', $uwuzuid);
$messageQuery->bindValue(':offset', $offset, PDO::PARAM_INT);
$messageQuery->bindValue(':itemsPerPage', $itemsPerPage, PDO::PARAM_INT);
$messageQuery->execute();
$message_array = $messageQuery->fetchAll();
@@ -134,6 +137,8 @@ if (isset($_GET['userid']) && isset($_GET['account_id'])) {
if(!empty($messages)){
foreach ($messages as $value) {
if (false === strpos($myblocklist, ','.htmlentities($value['account'], ENT_QUOTES, 'UTF-8'))) {
$value["bookmark"] = $mybookmark;
$fav = $value['favorite']; // コンマで区切られたユーザーIDを含む変数
// コンマで区切って配列に分割し、要素数を数える