diff --git a/.well-known/nodeinfo/index.php b/.well-known/nodeinfo/index.php
index e9980d4..50542ed 100644
--- a/.well-known/nodeinfo/index.php
+++ b/.well-known/nodeinfo/index.php
@@ -2,7 +2,7 @@
$serversettings_file = "../../server/serversettings.ini";
$serversettings = parse_ini_file($serversettings_file, true);
if(htmlspecialchars($serversettings["serverinfo"]["server_activitypub"], ENT_QUOTES, 'UTF-8') === "true"){
- header("Content-Type: application/json");
+ header("Content-Type: application/activity+json");
header("charset=utf-8");
header("Access-Control-Allow-Origin: *");
diff --git a/.well-known/webfinger/index.php b/.well-known/webfinger/index.php
index 2736205..e3588c5 100644
--- a/.well-known/webfinger/index.php
+++ b/.well-known/webfinger/index.php
@@ -2,7 +2,7 @@
$serversettings_file = "../../server/serversettings.ini";
$serversettings = parse_ini_file($serversettings_file, true);
if(htmlspecialchars($serversettings["serverinfo"]["server_activitypub"], ENT_QUOTES, 'UTF-8') === "true"){
- header("Content-Type: application/json");
+ header("Content-Type: application/jrd+json");
header("charset=utf-8");
header("Access-Control-Allow-Origin: *");
diff --git a/actor/index.php b/actor/index.php
index 3138f78..5ac671e 100644
--- a/actor/index.php
+++ b/actor/index.php
@@ -2,7 +2,7 @@
$serversettings_file = "../server/serversettings.ini";
$serversettings = parse_ini_file($serversettings_file, true);
if(htmlspecialchars($serversettings["serverinfo"]["server_activitypub"], ENT_QUOTES, 'UTF-8') === "true"){
- header("Content-Type: application/json");
+ header("Content-Type: application/activity+json");
header("charset=utf-8");
header("Access-Control-Allow-Origin: *");
@@ -47,6 +47,11 @@ if(htmlspecialchars($serversettings["serverinfo"]["server_activitypub"], ENT_QUO
"@context" => [
"https://www.w3.org/ns/activitystreams",
"https://w3id.org/security/v1",
+ array(
+ "schema" => "http://schema.org#",
+ "PropertyValue" => "schema:PropertyValue",
+ "value" => "schema:value",
+ ),
],
"id" => "https://".$domain."/actor/?actor=@".$userid."",
"type" => "Person",
diff --git a/addauthcode.php b/addauthcode.php
index 39cbf43..a339a18 100644
--- a/addauthcode.php
+++ b/addauthcode.php
@@ -185,6 +185,7 @@ $pdo = null;
+
diff --git a/admin/addadmin.php b/admin/addadmin.php
index c27008e..2edcaa7 100644
--- a/admin/addadmin.php
+++ b/admin/addadmin.php
@@ -122,7 +122,7 @@ if( !empty($_POST['btn_submit']) ) {
// アップロードされたファイル情報
$uploadedFile = $_FILES['image'];
- if(check_mime_video($uploadedFile['tmp_name'])){
+ if(check_mime($uploadedFile['tmp_name'])){
// アップロードされたファイルの拡張子を取得
$extension = pathinfo($uploadedFile['name'], PATHINFO_EXTENSION);
@@ -136,7 +136,7 @@ if( !empty($_POST['btn_submit']) ) {
delete_exif($extension, $uploadedFile['tmp_name']);
// ファイルを移動
- $result = move_uploaded_file($uploadedFile['tmp_name'], $uploadedPath);
+ $result = move_uploaded_file($uploadedFile['tmp_name'], '../'.$uploadedPath);
if ($result) {
$iconName = $uploadedPath; // 保存されたファイルのパスを使用
@@ -231,7 +231,7 @@ if( !empty($_POST['btn_submit']) ) {
$error_message[] = '表示名を入力してください。(USERNAME_INPUT_PLEASE)';
} else {
// 文字数を確認
- if( 25 < mb_strlen($username, 'UTF-8') ) {
+ if( 50 < mb_strlen($username, 'UTF-8') ) {
$error_message[] = 'ユーザーネームは50文字以内で入力してください。(USERNAME_OVER_MAX_COUNT)';
}
}
@@ -249,6 +249,9 @@ if( !empty($_POST['btn_submit']) ) {
if($result > 0){
$error_message[] = 'このID('.$userid.')は既に使用されています。他のIDを作成してください。(USERID_SHIYOUZUMI)';
}
+ if(!(preg_match("/^[a-zA-Z0-9_]+$/", $userid))){
+ $error_message[] = "IDは半角英数字で入力してください。(「_」は使用可能です。)(USERID_DONT_USE_WORD)";
+ }
}
@@ -337,8 +340,8 @@ if( !empty($_POST['btn_submit']) ) {
}
// 文字数を確認
- if( 100 < mb_strlen($password, 'UTF-8') ) {
- $error_message[] = 'パスワードは100文字以内で入力してください。(PASSWORD_OVER_MAX_COUNT)';
+ if( 256 < mb_strlen($password, 'UTF-8') ) {
+ $error_message[] = 'パスワードは256文字以内で入力してください。(PASSWORD_OVER_MAX_COUNT)';
}
}
@@ -431,6 +434,7 @@ $pdo = null;
+
diff --git a/admin/index.php b/admin/index.php
index 3472a37..b9a5d3c 100644
--- a/admin/index.php
+++ b/admin/index.php
@@ -75,6 +75,26 @@ if($result2 > 0){
exit;
}
+if (in_array("gd", get_loaded_extensions())) {
+ $check_gd = true;
+} else {
+ $check_gd = false;
+}
+if (in_array("fileinfo", get_loaded_extensions())) {
+ $check_fileinfo = true;
+} else {
+ $check_fileinfo = false;
+}
+if (in_array("mbstring", get_loaded_extensions())) {
+ $check_mbstring = true;
+} else {
+ $check_mbstring = false;
+}
+if (in_array("pdo_mysql", get_loaded_extensions())) {
+ $check_pdo_mysql = true;
+} else {
+ $check_pdo_mysql = false;
+}
// データベースの接続を閉じる
$pdo = null;
@@ -84,6 +104,7 @@ $pdo = null;
+
@@ -115,7 +136,15 @@ $pdo = null;
おめでとうございます!!!
uwuzuの導入が完了しました!
- これより管理者アカウントの登録を行います。
userロールとofficialロールの設定はお済みですか?
userロールとofficialロールがないとuwuzuは正しく動作しないので設定をしていない方は一度このページを閉じて設定してください!
また、php.iniよりGDの有効化または導入はお済みですか?GDがないとuwuzuは二段階認証が正しく動作しないため絶対に設定してください!
+ これより管理者アカウントの登録を行います。
userロールとofficialロール、iceロールの設定はお済みですか?
userロールとofficialロール、iceロールがないとuwuzuは正しく動作しないので設定をしていない方は一度このページを閉じて設定してください!
また、php.iniよりGDの有効化または導入はお済みですか?GDがないとuwuzuは二段階認証が正しく動作しないため絶対に設定してください!
+
+
+
GD :
+
Fileinfo :
+
mbstring :
+
pdo_mysql :
+
+
uwuzu
Version :
diff --git a/admin/success.php b/admin/success.php
index 22e0e1c..9508344 100644
--- a/admin/success.php
+++ b/admin/success.php
@@ -79,6 +79,7 @@ if(!(empty($_SESSION['backupcode']))){
+
diff --git a/api/bot-api.php b/api/bot-api.php
index 5e71f39..70b33cf 100644
--- a/api/bot-api.php
+++ b/api/bot-api.php
@@ -299,7 +299,7 @@ if(isset($_GET['token'])&&isset($_GET['type'])) {
}
if($type === "reply"){
- if(isset($_GET['ueuse'])) {
+ if(isset($_GET['ueuse']) && isset($_GET['uniqid'])) {
$rpuniqid = htmlentities($_GET['uniqid']);
$ueuse = nl2br(htmlentities($_GET['ueuse']));
@@ -679,6 +679,422 @@ if(isset($_GET['token'])&&isset($_GET['type'])) {
}
}
+ if($type === "getuser_from_userid"){
+
+ if(isset($_GET['userid'])) {
+ $userid = htmlentities($_GET['userid']);
+
+ if($token === 'ice'){
+ $err = "this_account_has_been_frozen";
+ $response = array(
+ 'error_code' => $err,
+ );
+ echo json_encode($response, JSON_UNESCAPED_UNICODE);
+ exit;
+ }elseif($token === ''){
+ $err = "token_input_error";
+ $response = array(
+ 'error_code' => $err,
+ );
+ echo json_encode($response, JSON_UNESCAPED_UNICODE);
+ exit;
+ }
+
+ require('../db.php');
+
+ $datetime = array();
+ $pdo = null;
+
+ session_start();
+
+ try {
+ $option = array(
+ PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
+ PDO::MYSQL_ATTR_MULTI_STATEMENTS => false
+ );
+ $pdo = new PDO('mysql:charset=utf8mb4;dbname='.DB_NAME.';host='.DB_HOST , DB_USER, DB_PASS, $option);
+ } catch(PDOException $e) {
+ // 接続エラーのときエラー内容を取得する
+ $error_message[] = $e->getMessage();
+ }
+
+
+ if (!empty($pdo)) {
+
+ // データベース接続の設定
+ $dbh = new PDO('mysql:charset=utf8mb4;dbname='.DB_NAME.';host='.DB_HOST, DB_USER, DB_PASS, array(
+ PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
+ PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC,
+ PDO::MYSQL_ATTR_USE_BUFFERED_QUERY => true,
+ ));
+
+ $userQuery = $dbh->prepare("SELECT username, userid,role FROM account WHERE token = :token");
+ $userQuery->bindValue(':token', $token);
+ $userQuery->execute();
+ $userData = $userQuery->fetch();
+
+ if(empty($userData["userid"])){
+ $err = "token_invalid";
+ $response = array(
+ 'error_code' => $err,
+ );
+ echo json_encode($response, JSON_UNESCAPED_UNICODE);
+ exit;
+ }elseif($userData["role"] === "ice"){
+ $err = "this_account_has_been_frozen";
+ $response = array(
+ 'error_code' => $err,
+ );
+
+ echo json_encode($response, JSON_UNESCAPED_UNICODE);
+ exit;
+ }else{
+ $userQuery = $pdo->prepare("SELECT username,userid,profile,datetime,follow,follower,iconname,headname FROM account WHERE userid = :userid");
+ $userQuery->bindValue(':userid', $userid);
+ $userQuery->execute();
+ $userdata = $userQuery->fetch();
+
+ if (empty($userdata)){
+ $response = array(
+ 'error_code' => "userid_not_found",
+ );
+ }else{
+ $followcnts = explode(',', $userdata["follow"]);
+ $userdata["follow_cnt"] = count($followcnts)-1;
+
+ $followercnts = explode(',', $userdata["follower"]);
+ $userdata["follower_cnt"] = count($followercnts)-1;
+
+ $response = array(
+ 'user_name' => decode_yajirushi(htmlspecialchars_decode($userdata["username"])),
+ 'user_id' => decode_yajirushi(htmlspecialchars_decode($userdata["userid"])),
+ 'profile' => decode_yajirushi(htmlspecialchars_decode($userdata["profile"])),
+ 'user_icon' => decode_yajirushi(htmlspecialchars_decode("https://".$domain."/".$userdata["iconname"])),
+ 'user_header' => decode_yajirushi(htmlspecialchars_decode("https://".$domain."/".$userdata["headname"])),
+ 'registered_date' => decode_yajirushi(htmlspecialchars_decode($userdata["datetime"])),
+ 'follow' => decode_yajirushi(htmlspecialchars_decode($userdata["follow"])),
+ 'follow_cnt' => decode_yajirushi(htmlspecialchars_decode($userdata["follow_cnt"])),
+ 'follower' => decode_yajirushi(htmlspecialchars_decode($userdata["follower"])),
+ 'follower_cnt' => decode_yajirushi(htmlspecialchars_decode($userdata["follower_cnt"])),
+ );
+ }
+ echo json_encode($response, JSON_UNESCAPED_UNICODE);
+ }
+ }
+
+ }else{
+ $err = "input_not_found";
+ $response = array(
+ 'error_code' => $err,
+ );
+ echo json_encode($response, JSON_UNESCAPED_UNICODE);
+ exit;
+ }
+ }
+
+ if($type === "getltl"){
+
+ if(isset($_GET['limit'])) {
+
+ $itemsPerPage = htmlentities((int)$_GET['limit']); // 1ページあたりの投稿数
+ if(isset($_GET['page'])) {
+ $pageNumber = htmlentities((int)$_GET['page']);
+ if(!(is_int($pageNumber))){
+ $pageNumber = 1;
+ }
+ }else{
+ $pageNumber = 1;
+ }
+ $offset = ($pageNumber - 1) * $itemsPerPage;
+
+ $messages = array();
+
+ if($token === 'ice'){
+ $err = "this_account_has_been_frozen";
+ $response = array(
+ 'error_code' => $err,
+ );
+ echo json_encode($response, JSON_UNESCAPED_UNICODE);
+ exit;
+ }elseif($token === ''){
+ $err = "token_input_error";
+ $response = array(
+ 'error_code' => $err,
+ );
+ echo json_encode($response, JSON_UNESCAPED_UNICODE);
+ exit;
+ }
+
+ require('../db.php');
+
+ $datetime = array();
+ $pdo = null;
+
+ session_start();
+
+ try {
+ $option = array(
+ PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
+ PDO::MYSQL_ATTR_MULTI_STATEMENTS => false
+ );
+ $pdo = new PDO('mysql:charset=utf8mb4;dbname='.DB_NAME.';host='.DB_HOST , DB_USER, DB_PASS, $option);
+ } catch(PDOException $e) {
+ // 接続エラーのときエラー内容を取得する
+ $error_message[] = $e->getMessage();
+ }
+
+
+ if (!empty($pdo)) {
+
+ // データベース接続の設定
+ $dbh = new PDO('mysql:charset=utf8mb4;dbname='.DB_NAME.';host='.DB_HOST, DB_USER, DB_PASS, array(
+ PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
+ PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC,
+ PDO::MYSQL_ATTR_USE_BUFFERED_QUERY => true,
+ ));
+
+ $userQuery = $dbh->prepare("SELECT username, userid,role FROM account WHERE token = :token");
+ $userQuery->bindValue(':token', $token);
+ $userQuery->execute();
+ $userData = $userQuery->fetch();
+
+ if(empty($userData["userid"])){
+ $err = "token_invalid";
+ $response = array(
+ 'error_code' => $err,
+ );
+ echo json_encode($response, JSON_UNESCAPED_UNICODE);
+ exit;
+ }elseif($userData["role"] === "ice"){
+ $err = "this_account_has_been_frozen";
+ $response = array(
+ 'error_code' => $err,
+ );
+
+ echo json_encode($response, JSON_UNESCAPED_UNICODE);
+ exit;
+ }else{
+
+ $sql = "SELECT ueuse.*
+ FROM ueuse
+ LEFT JOIN account ON ueuse.account = account.userid
+ WHERE ueuse.rpuniqid = '' AND account.role != 'ice'
+ ORDER BY ueuse.datetime DESC
+ LIMIT :offset, :itemsPerPage";
+
+ $stmt = $pdo->prepare($sql);
+ $stmt->bindValue(':offset', $offset, PDO::PARAM_INT);
+ $stmt->bindValue(':itemsPerPage', $itemsPerPage, PDO::PARAM_INT);
+ $stmt->execute();
+ $message_array = $stmt;
+
+ while ($row = $message_array->fetch(PDO::FETCH_ASSOC)) {
+
+ $messages[] = $row;
+ }
+
+ // ユーザー情報を取得して、$messages内のusernameをuserDataのusernameに置き換える
+ foreach ($messages as &$message) {
+ $userQuery = $pdo->prepare("SELECT username, userid, profile, role FROM account WHERE userid = :userid");
+ $userQuery->bindValue(':userid', $message["account"]);
+ $userQuery->execute();
+ $userData = $userQuery->fetch();
+
+ if ($userData) {
+ $message['username'] = $userData['username'];
+ $message['role'] = $userData['role'];
+ }
+ }
+
+ if (!empty($messages)) {
+ $response = array(); // ループ外で $response を初期化
+
+ foreach ($messages as $ueusedata) {
+ $favcnts = explode(',', $ueusedata["favorite"]);
+ $ueusedata["favorite_cnt"] = count($favcnts) - 1;
+
+ $item = [
+ 'account' => decode_yajirushi(htmlspecialchars_decode($ueusedata["account"])),
+ 'username' => decode_yajirushi(htmlspecialchars_decode($ueusedata["username"])),
+ 'uniqid' => decode_yajirushi(htmlspecialchars_decode($ueusedata["uniqid"])),
+ 'ueuse' => decode_yajirushi(htmlspecialchars_decode($ueusedata["ueuse"])),
+ 'photo1' => decode_yajirushi(htmlspecialchars_decode(str_replace('../', 'https://' . $_SERVER['HTTP_HOST'] . '/', $ueusedata["photo1"]))),
+ 'photo2' => decode_yajirushi(htmlspecialchars_decode(str_replace('../', 'https://' . $_SERVER['HTTP_HOST'] . '/', $ueusedata["photo2"]))),
+ 'photo3' => decode_yajirushi(htmlspecialchars_decode(str_replace('../', 'https://' . $_SERVER['HTTP_HOST'] . '/', $ueusedata["photo3"]))),
+ 'photo4' => decode_yajirushi(htmlspecialchars_decode(str_replace('../', 'https://' . $_SERVER['HTTP_HOST'] . '/', $ueusedata["photo4"]))),
+ 'video1' => decode_yajirushi(htmlspecialchars_decode(str_replace('../', 'https://' . $_SERVER['HTTP_HOST'] . '/', $ueusedata["video1"]))),
+ 'favorite' => decode_yajirushi(htmlspecialchars_decode($ueusedata["favorite"])),
+ 'favorite_cnt' => decode_yajirushi(htmlspecialchars_decode($ueusedata["favorite_cnt"])),
+ 'datetime' => decode_yajirushi(htmlspecialchars_decode($ueusedata["datetime"])),
+ 'abi' => decode_yajirushi(htmlspecialchars_decode($ueusedata["abi"])),
+ 'abidatetime' => decode_yajirushi(htmlspecialchars_decode($ueusedata["abidate"])),
+ 'nsfw' => decode_yajirushi(htmlspecialchars_decode($ueusedata["nsfw"])),
+ ];
+
+ $response[$ueusedata["uniqid"]] = $item; // ループ内で $response にデータを追加
+ }
+
+ echo json_encode($response, JSON_UNESCAPED_UNICODE);
+ } else {
+ $err = "ueuse_not_found";
+ $response = array(
+ 'error_code' => $err,
+ );
+
+ echo json_encode($response, JSON_UNESCAPED_UNICODE);
+ }
+
+
+ $pdo = null;
+ }
+ }
+
+ }else{
+ $err = "input_not_found";
+ $response = array(
+ 'error_code' => $err,
+ );
+ echo json_encode($response, JSON_UNESCAPED_UNICODE);
+ exit;
+ }
+ }
+
+ if($type === "getueuse"){
+
+ if(isset($_GET['ueuseid'])) {
+
+ $ueuseid = htmlentities($_GET['ueuseid']);
+
+ if($token === 'ice'){
+ $err = "this_account_has_been_frozen";
+ $response = array(
+ 'error_code' => $err,
+ );
+ echo json_encode($response, JSON_UNESCAPED_UNICODE);
+ exit;
+ }elseif($token === ''){
+ $err = "token_input_error";
+ $response = array(
+ 'error_code' => $err,
+ );
+ echo json_encode($response, JSON_UNESCAPED_UNICODE);
+ exit;
+ }
+
+ require('../db.php');
+
+ $datetime = array();
+ $pdo = null;
+
+ session_start();
+
+ try {
+ $option = array(
+ PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
+ PDO::MYSQL_ATTR_MULTI_STATEMENTS => false
+ );
+ $pdo = new PDO('mysql:charset=utf8mb4;dbname='.DB_NAME.';host='.DB_HOST , DB_USER, DB_PASS, $option);
+ } catch(PDOException $e) {
+ // 接続エラーのときエラー内容を取得する
+ $error_message[] = $e->getMessage();
+ }
+
+
+ if (!empty($pdo)) {
+
+ // データベース接続の設定
+ $dbh = new PDO('mysql:charset=utf8mb4;dbname='.DB_NAME.';host='.DB_HOST, DB_USER, DB_PASS, array(
+ PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
+ PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC,
+ PDO::MYSQL_ATTR_USE_BUFFERED_QUERY => true,
+ ));
+
+ $userQuery = $dbh->prepare("SELECT username, userid,role FROM account WHERE token = :token");
+ $userQuery->bindValue(':token', $token);
+ $userQuery->execute();
+ $userData = $userQuery->fetch();
+
+ if(empty($userData["userid"])){
+ $err = "token_invalid";
+ $response = array(
+ 'error_code' => $err,
+ );
+ echo json_encode($response, JSON_UNESCAPED_UNICODE);
+ exit;
+ }elseif($userData["role"] === "ice"){
+ $err = "this_account_has_been_frozen";
+ $response = array(
+ 'error_code' => $err,
+ );
+
+ echo json_encode($response, JSON_UNESCAPED_UNICODE);
+ exit;
+ }else{
+
+ $dbh = new PDO('mysql:charset=utf8mb4;dbname='.DB_NAME.';host='.DB_HOST, DB_USER, DB_PASS, array(
+ PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
+ PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC,
+ PDO::MYSQL_ATTR_USE_BUFFERED_QUERY => true,
+ ));
+
+ $ueuseQuery = $pdo->prepare("SELECT * FROM ueuse WHERE uniqid = :ueuseid");
+ $ueuseQuery->bindValue(':ueuseid', $ueuseid);
+ $ueuseQuery->execute();
+ $ueusedata = $ueuseQuery->fetch();
+
+ if (empty($ueusedata)){
+ $response = array(
+ 'error_code' => "ueuseid_not_found",
+ );
+ }else{
+ $userQuery = $pdo->prepare("SELECT username, userid, profile, role FROM account WHERE userid = :userid");
+ $userQuery->bindValue(':userid', $ueusedata["account"]);
+ $userQuery->execute();
+ $userData = $userQuery->fetch();
+ if ($userData) {
+ $ueusedata['username'] = $userData['username'];
+ $ueusedata['role'] = $userData['role'];
+ }
+
+
+ $favcnts = explode(',', $ueusedata["favorite"]);
+ $ueusedata["favorite_cnt"] = count($favcnts)-1;
+
+ $response = array(
+ 'account' => decode_yajirushi(htmlspecialchars_decode($ueusedata["account"])),
+ 'username' => decode_yajirushi(htmlspecialchars_decode($ueusedata["username"])),
+ 'uniqid' => decode_yajirushi(htmlspecialchars_decode($ueusedata["uniqid"])),
+ 'ueuse' => decode_yajirushi(htmlspecialchars_decode($ueusedata["ueuse"])),
+ 'photo1' => decode_yajirushi(htmlspecialchars_decode(str_replace('../', 'https://' . $_SERVER['HTTP_HOST'] . '/', $ueusedata["photo1"]))),
+ 'photo2' => decode_yajirushi(htmlspecialchars_decode(str_replace('../', 'https://' . $_SERVER['HTTP_HOST'] . '/', $ueusedata["photo2"]))),
+ 'photo3' => decode_yajirushi(htmlspecialchars_decode(str_replace('../', 'https://' . $_SERVER['HTTP_HOST'] . '/', $ueusedata["photo3"]))),
+ 'photo4' => decode_yajirushi(htmlspecialchars_decode(str_replace('../', 'https://' . $_SERVER['HTTP_HOST'] . '/', $ueusedata["photo4"]))),
+ 'video1' => decode_yajirushi(htmlspecialchars_decode(str_replace('../', 'https://' . $_SERVER['HTTP_HOST'] . '/', $ueusedata["video1"]))),
+ 'favorite' => decode_yajirushi(htmlspecialchars_decode($ueusedata["favorite"])),
+ 'favorite_cnt' => decode_yajirushi(htmlspecialchars_decode($ueusedata["favorite_cnt"])),
+ 'datetime' => decode_yajirushi(htmlspecialchars_decode($ueusedata["datetime"])),
+ 'abi' => decode_yajirushi(htmlspecialchars_decode($ueusedata["abi"])),
+ 'abidatetime' => decode_yajirushi(htmlspecialchars_decode($ueusedata["abidate"])),
+ 'nsfw' => decode_yajirushi(htmlspecialchars_decode($ueusedata["nsfw"])),
+ );
+ }
+ echo json_encode($response, JSON_UNESCAPED_UNICODE);
+
+
+ $pdo = null;
+ }
+ }
+
+ }else{
+ $err = "input_not_found";
+ $response = array(
+ 'error_code' => $err,
+ );
+ echo json_encode($response, JSON_UNESCAPED_UNICODE);
+ exit;
+ }
+ }
+
}else{
$err = "input_not_found";
diff --git a/api/ltl-api.php b/api/ltl-api.php
index 5b1213b..ebc48e7 100644
--- a/api/ltl-api.php
+++ b/api/ltl-api.php
@@ -2,116 +2,12 @@
header("Content-Type: application/json");
header("charset=utf-8");
header("Access-Control-Allow-Origin: *");
-function decode_yajirushi($postText){
- $postText = str_replace('←', '←', $postText);
- $postText = str_replace('↓', '↓', $postText);
- $postText = str_replace('↑', '↑', $postText);
- $postText = str_replace('→', '→', $postText);
- return $postText;
-}
-if(isset($_GET['limit'])) {
- $itemsPerPage = htmlentities((int)$_GET['limit']); // 1ページあたりの投稿数
- if(isset($_GET['page'])) {
- $pageNumber = htmlentities((int)$_GET['page']);
- }else{
- $pageNumber = 1;
- }
- $offset = ($pageNumber - 1) * $itemsPerPage;
+$err = "API_has_been_deleted";
+$response = array(
+ 'error_code' => $err,
+);
+
+echo json_encode($response, JSON_UNESCAPED_UNICODE);
- $messages = array();
-
- require('../db.php');
-
- $datetime = array();
- $pdo = null;
-
- session_start();
-
- try {
-
- $option = array(
- PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
- PDO::MYSQL_ATTR_MULTI_STATEMENTS => false
- );
- $pdo = new PDO('mysql:charset=utf8mb4;dbname='.DB_NAME.';host='.DB_HOST , DB_USER, DB_PASS, $option);
-
- } catch(PDOException $e) {
-
- // 接続エラーのときエラー内容を取得する
- $error_message[] = $e->getMessage();
- }
-
-
- if (!empty($pdo)) {
- $sql = "SELECT account, username, uniqid, rpuniqid, ueuse, datetime, photo1, photo2, video1, favorite, abi, abidate, nsfw FROM ueuse WHERE rpuniqid = '' ORDER BY datetime DESC LIMIT " . intval($offset) . ", " . intval($itemsPerPage);
- $message_array = $pdo->query($sql);
-
- while ($row = $message_array->fetch(PDO::FETCH_ASSOC)) {
-
- $messages[] = $row;
- }
-
- // ユーザー情報を取得して、$messages内のusernameをuserDataのusernameに置き換える
- foreach ($messages as &$message) {
- $userQuery = $pdo->prepare("SELECT username, userid, profile, role FROM account WHERE userid = :userid");
- $userQuery->bindValue(':userid', $message["account"]);
- $userQuery->execute();
- $userData = $userQuery->fetch();
-
- if ($userData) {
- $message['username'] = $userData['username'];
- $message['role'] = $userData['role'];
- }
- }
-
- if (!empty($messages)) {
- $response = array(); // ループ外で $response を初期化
-
- foreach ($messages as $ueusedata) {
- $favcnts = explode(',', $ueusedata["favorite"]);
- $ueusedata["favorite_cnt"] = count($favcnts) - 1;
-
- $item = [
- 'account' => decode_yajirushi(htmlspecialchars_decode($ueusedata["account"])),
- 'username' => decode_yajirushi(htmlspecialchars_decode($ueusedata["username"])),
- 'uniqid' => decode_yajirushi(htmlspecialchars_decode($ueusedata["uniqid"])),
- 'ueuse' => decode_yajirushi(htmlspecialchars_decode($ueusedata["ueuse"])),
- 'photo1' => decode_yajirushi(htmlspecialchars_decode(str_replace('../', '' . $_SERVER['HTTP_HOST'] . '/', $ueusedata["photo1"]))),
- 'photo2' => decode_yajirushi(htmlspecialchars_decode(str_replace('../', '' . $_SERVER['HTTP_HOST'] . '/', $ueusedata["photo2"]))),
- 'video1' => decode_yajirushi(htmlspecialchars_decode(str_replace('../', '' . $_SERVER['HTTP_HOST'] . '/', $ueusedata["video1"]))),
- 'favorite' => decode_yajirushi(htmlspecialchars_decode($ueusedata["favorite"])),
- 'favorite_cnt' => decode_yajirushi(htmlspecialchars_decode($ueusedata["favorite_cnt"])),
- 'datetime' => decode_yajirushi(htmlspecialchars_decode($ueusedata["datetime"])),
- 'abi' => decode_yajirushi(htmlspecialchars_decode($ueusedata["abi"])),
- 'abidatetime' => decode_yajirushi(htmlspecialchars_decode($ueusedata["abidate"])),
- 'nsfw' => decode_yajirushi(htmlspecialchars_decode($ueusedata["nsfw"])),
- ];
-
- $response[$ueusedata["uniqid"]] = $item; // ループ内で $response にデータを追加
- }
-
- echo json_encode($response, JSON_UNESCAPED_UNICODE);
- } else {
- $err = "ueuse_not_found";
- $response = array(
- 'error_code' => $err,
- );
-
- echo json_encode($response, JSON_UNESCAPED_UNICODE);
- }
-
-
- $pdo = null;
- }
-
-}else{
-
- $err = "input_not_found";
- $response = array(
- 'error_code' => $err,
- );
-
- echo json_encode($response, JSON_UNESCAPED_UNICODE);
-}
?>
\ No newline at end of file
diff --git a/api/ueuse-api.php b/api/ueuse-api.php
index cdcf142..ebc48e7 100644
--- a/api/ueuse-api.php
+++ b/api/ueuse-api.php
@@ -2,96 +2,12 @@
header("Content-Type: application/json");
header("charset=utf-8");
header("Access-Control-Allow-Origin: *");
-function decode_yajirushi($postText){
- $postText = str_replace('←', '←', $postText);
- $postText = str_replace('↓', '↓', $postText);
- $postText = str_replace('↑', '↑', $postText);
- $postText = str_replace('→', '→', $postText);
- return $postText;
-}
-if(isset($_GET['ueuseid'])) {
-$ueuseid = htmlentities($_GET['ueuseid']);
+$err = "API_has_been_deleted";
+$response = array(
+ 'error_code' => $err,
+);
+
+echo json_encode($response, JSON_UNESCAPED_UNICODE);
-
-require('../db.php');
-
-$datetime = array();
-$pdo = null;
-
-session_start();
-
- try {
-
- $option = array(
- PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
- PDO::MYSQL_ATTR_MULTI_STATEMENTS => false
- );
- $pdo = new PDO('mysql:charset=utf8mb4;dbname='.DB_NAME.';host='.DB_HOST , DB_USER, DB_PASS, $option);
-
- } catch(PDOException $e) {
-
- // 接続エラーのときエラー内容を取得する
- $error_message[] = $e->getMessage();
- }
-
-
- if (!empty($pdo)) {
-
- $dbh = new PDO('mysql:charset=utf8mb4;dbname='.DB_NAME.';host='.DB_HOST, DB_USER, DB_PASS, array(
- PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
- PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC,
- PDO::MYSQL_ATTR_USE_BUFFERED_QUERY => true,
- ));
-
- $ueuseQuery = $pdo->prepare("SELECT account, ueuse, uniqid, rpuniqid, datetime, photo1, photo2, video1, favorite, abi, abidate FROM ueuse WHERE uniqid = :ueuseid");
- $ueuseQuery->bindValue(':ueuseid', $ueuseid);
- $ueuseQuery->execute();
- $ueusedata = $ueuseQuery->fetch();
- }
-
-if (empty($ueusedata)){
- $response = array(
- 'error_code' => "ueuseid_not_found",
- );
-}else{
- $userQuery = $pdo->prepare("SELECT username, userid, profile, role FROM account WHERE userid = :userid");
- $userQuery->bindValue(':userid', $ueusedata["account"]);
- $userQuery->execute();
- $userData = $userQuery->fetch();
- if ($userData) {
- $ueusedata['username'] = $userData['username'];
- $ueusedata['role'] = $userData['role'];
- }
-
-
- $favcnts = explode(',', $ueusedata["favorite"]);
- $ueusedata["favorite_cnt"] = count($favcnts)-1;
-
- $response = array(
- 'userid' => decode_yajirushi(htmlspecialchars_decode($ueusedata["account"])),
- 'user_name' => decode_yajirushi(htmlspecialchars_decode($ueusedata["username"])),
- 'uniqid' => decode_yajirushi(htmlspecialchars_decode($ueusedata["uniqid"])),
- 'ueuse' => decode_yajirushi(htmlspecialchars_decode($ueusedata["ueuse"])),
- 'photo1' => decode_yajirushi(htmlspecialchars_decode(str_replace('../', ''.$_SERVER['HTTP_HOST'].'/', $ueusedata["photo1"]))),
- 'photo2' => decode_yajirushi(htmlspecialchars_decode(str_replace('../', ''.$_SERVER['HTTP_HOST'].'/', $ueusedata["photo2"]))),
- 'video1' => decode_yajirushi(htmlspecialchars_decode(str_replace('../', ''.$_SERVER['HTTP_HOST'].'/', $ueusedata["video1"]))),
- 'favorite' => decode_yajirushi(htmlspecialchars_decode($ueusedata["favorite"])),
- 'favorite_cnt' => decode_yajirushi(htmlspecialchars_decode($ueusedata["favorite_cnt"])),
- 'datetime' => decode_yajirushi(htmlspecialchars_decode($ueusedata["datetime"])),
- 'abi' => decode_yajirushi(htmlspecialchars_decode($ueusedata["abi"])),
- 'abidatetime' => decode_yajirushi(htmlspecialchars_decode($ueusedata["abidate"])),
- );
-}
-echo json_encode($response, JSON_UNESCAPED_UNICODE);;
-
-}else{
-
- $err = "input_not_found";
- $response = array(
- 'error_code' => $err,
- );
-
- echo json_encode($response, JSON_UNESCAPED_UNICODE);
-}
?>
\ No newline at end of file
diff --git a/api/userdata-api.php b/api/userdata-api.php
index 4e664f0..ebc48e7 100644
--- a/api/userdata-api.php
+++ b/api/userdata-api.php
@@ -2,87 +2,12 @@
header("Content-Type: application/json");
header("charset=utf-8");
header("Access-Control-Allow-Origin: *");
-function decode_yajirushi($postText){
- $postText = str_replace('←', '←', $postText);
- $postText = str_replace('↓', '↓', $postText);
- $postText = str_replace('↑', '↑', $postText);
- $postText = str_replace('→', '→', $postText);
- return $postText;
-}
-if(isset($_GET['userid'])) {
-$search = htmlentities($_GET['userid']);
-
-$domain = $_SERVER['HTTP_HOST'];
-
-require('../db.php');
-
-$datetime = array();
-$pdo = null;
-
-session_start();
-
- try {
-
- $option = array(
- PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
- PDO::MYSQL_ATTR_MULTI_STATEMENTS => false
- );
- $pdo = new PDO('mysql:charset=utf8mb4;dbname='.DB_NAME.';host='.DB_HOST , DB_USER, DB_PASS, $option);
-
- } catch(PDOException $e) {
-
- // 接続エラーのときエラー内容を取得する
- $error_message[] = $e->getMessage();
- }
-
-
- if (!empty($pdo)) {
-
- $dbh = new PDO('mysql:charset=utf8mb4;dbname='.DB_NAME.';host='.DB_HOST, DB_USER, DB_PASS, array(
- PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
- PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC,
- PDO::MYSQL_ATTR_USE_BUFFERED_QUERY => true,
- ));
-
- $userQuery = $pdo->prepare("SELECT username,userid,profile,datetime,follow,follower,iconname,headname FROM account WHERE userid = :userid");
- $userQuery->bindValue(':userid', $search);
- $userQuery->execute();
- $userdata = $userQuery->fetch();
- }
-if (empty($userdata)){
- $response = array(
- 'error_code' => "userid_not_found",
- );
-}else{
- $followcnts = explode(',', $userdata["follow"]);
- $userdata["follow_cnt"] = count($followcnts)-1;
-
- $followercnts = explode(',', $userdata["follower"]);
- $userdata["follower_cnt"] = count($followercnts)-1;
-
- $response = array(
- 'user_name' => decode_yajirushi(htmlspecialchars_decode($userdata["username"])),
- 'user_id' => decode_yajirushi(htmlspecialchars_decode($userdata["userid"])),
- 'profile' => decode_yajirushi(htmlspecialchars_decode($userdata["profile"])),
- 'user_icon' => decode_yajirushi(htmlspecialchars_decode("https://".$domain."/".$userdata["iconname"])),
- 'user_header' => decode_yajirushi(htmlspecialchars_decode("https://".$domain."/".$userdata["headname"])),
- 'registered_date' => decode_yajirushi(htmlspecialchars_decode($userdata["datetime"])),
- 'follow' => decode_yajirushi(htmlspecialchars_decode($userdata["follow"])),
- 'follow_cnt' => decode_yajirushi(htmlspecialchars_decode($userdata["follow_cnt"])),
- 'follower' => decode_yajirushi(htmlspecialchars_decode($userdata["follower"])),
- 'follower_cnt' => decode_yajirushi(htmlspecialchars_decode($userdata["follower_cnt"])),
- );
-}
+$err = "API_has_been_deleted";
+$response = array(
+ 'error_code' => $err,
+);
+
echo json_encode($response, JSON_UNESCAPED_UNICODE);
-}else{
-
- $err = "input_not_found";
- $response = array(
- 'error_code' => $err,
- );
-
- echo json_encode($response, JSON_UNESCAPED_UNICODE);
-}
?>
\ No newline at end of file
diff --git a/authcodechk.php b/authcodechk.php
index c479fca..16c1989 100644
--- a/authcodechk.php
+++ b/authcodechk.php
@@ -130,6 +130,7 @@ $pdo = null;
+
diff --git a/authlogin.php b/authlogin.php
index 4722141..c283b64 100644
--- a/authlogin.php
+++ b/authlogin.php
@@ -289,6 +289,7 @@ $pdo = null;
+
diff --git a/bookmark/index.php b/bookmark/index.php
index c6d6ecc..76dac13 100644
--- a/bookmark/index.php
+++ b/bookmark/index.php
@@ -200,7 +200,7 @@ $pdo = null;
-
+
@@ -282,10 +282,17 @@ $pdo = null;
+
+
+
![]()
+
+
+
+
diff --git a/check.php b/check.php
index 641fb07..b64a233 100644
--- a/check.php
+++ b/check.php
@@ -78,7 +78,7 @@ try {
$roleDataArray = array();
foreach ($roles as $roleId) {
- $rerole = $dbh->prepare("SELECT rolename, roleauth, rolecolor FROM role WHERE roleidname = :role");
+ $rerole = $dbh->prepare("SELECT rolename, roleauth, rolecolor, roleeffect FROM role WHERE roleidname = :role");
$rerole->bindValue(':role', $roleId);
$rerole->execute();
$roleDataArray[$roleId] = $rerole->fetch();
@@ -277,6 +277,7 @@ $pdo = null;
+
@@ -318,9 +319,20 @@ $pdo = null;
-
;">
+
+
diff --git a/css/color.css b/css/color.css
index edfa731..8532c3c 100644
--- a/css/color.css
+++ b/css/color.css
@@ -1,7 +1,7 @@
:root {
--main-color: #FFC832;
--sub-color: #FFFAE6;
- --background-color: #f5f5f5;
+ --background-color: #F5F5F5;
--tl-color: #F7F7F7;
--ueuse-color:#f5f5f5;
--text-color: #252525;
diff --git a/css/home.css b/css/home.css
index 70f0461..c0fcfa9 100644
--- a/css/home.css
+++ b/css/home.css
@@ -46,15 +46,12 @@ body{
cursor: pointer;
border: none;
display: block;
- width:50%;
+ width: fit-content;
margin: 32px;
- padding: 8px 5%;
+ padding: 8px 20%;
margin-left: auto;
margin-right: auto;
- padding-top: 8px;
- padding-bottom: 8px;
-
background-color: var(--main-color);
text-align: center;
@@ -66,31 +63,27 @@ body{
text-decoration:none;
text-align: center;
box-shadow:0 0px 48px 0 rgba(0, 0, 0, .15);
- transition: box-shadow 250ms ease-in-out;
- transition: width 250ms ease-out;
+ transition: all 250ms ease-in-out;
}
.irobutton:hover{
box-shadow:0 0px 48px 0 rgba(0, 0, 0, .2);
- width:55%;
+ padding: 8px 22%;
}
.irobutton:active{
box-shadow:0 0px 48px 0 rgba(0, 0, 0, .05);
- width:45%;
+ padding: 8px 18%;
}
.sirobutton{
cursor: pointer;
border: none;
display: block;
- width:40%;
+ width: fit-content;
margin: 32px;
- padding: 8px 10%;
+ padding: 8px 20%;
margin-left: auto;
margin-right: auto;
- padding-top: 8px;
- padding-bottom: 8px;
-
text-align: center;
background-color: var(--sub-color);
@@ -102,16 +95,15 @@ body{
font-weight: normal;
text-decoration:none;
box-shadow:0 0px 48px 0 rgba(0, 0, 0, .15);
- transition: box-shadow 250ms ease-in-out;
- transition: width 250ms ease-out;
+ transition: all 250ms ease-in-out;
}
.sirobutton:hover{
box-shadow:0 0px 48px 0 rgba(0, 0, 0, .2);
- width:45%;
+ padding: 8px 22%;
}
.sirobutton:active{
- box-shadow:0 0px 48px 0 rgba(0, 0, 0, .05);
- width:45%;
+ box-shadow:0 0px 48px 0 rgba(0, 0, 0, .2);
+ padding: 8px 18%;
}
.inbox {
@@ -242,41 +234,125 @@ textarea{
}
-.rolebox{
-
- margin-top: 12px;
- margin-bottom: 12px;
-
- margin-left: auto;
- margin-right: auto;
-
- width: 120px;
+.rolebox {
+ margin: 4px 6px 4px 6px;
+ width: auto;
padding-left: auto;
padding-right: auto;
-
- background-color: var(--background-color);
- border: 1px solid var(--main-color);
-
border-radius: 25px;
box-shadow:0 0px 48px 0 rgba(0, 0, 0, .15);
-
}
-
-.rolebox p{
-
- color:var(--main-color);
- margin-top: 2px;
- margin-bottom: 2px;
- margin-left: 10px;
- margin-right: 10px;
-
- text-align: center;
+
+.rolebox p {
+ margin: 2px 10px 2px 10px;
font-size: 16px;
- font-family: 'Zen Maru Gothic', sans-serif;
+ font-family: "Zen Maru Gothic", sans-serif;
font-weight: normal;
-
}
+.roleboxes {
+ margin-left: auto;
+ margin-right: auto;
+ display: table;
+ padding: auto;
+ flex-wrap: wrap;
+}
+
+.shine {
+ position: relative;
+ overflow: hidden;
+}
+.shine:after {
+ content: "";
+ position: absolute;
+ top: -50%;
+ left: -50%;
+ width: 10%;
+ height: 150%;
+ background: #fff;
+ transform: rotate(45deg);
+ animation: reflect 3s ease-in-out infinite;
+}
+@keyframes reflect {
+ 0%,
+ 75% {
+ transform: rotate(45deg) scale(0);
+ opacity: 1;
+ }
+
+ 100% {
+ transform: rotate(45deg) scale(100);
+ opacity: 0;
+ }
+}
+.cyclingmark {
+ display: flex;
+}
+.cyclingmark p::before {
+ content: "";
+ display: inline-block;
+ width: 16px;
+ height: 16px;
+ vertical-align: middle;
+ margin-right: 5px;
+ background: url("/img/uwuzuicon.png")
+ no-repeat;
+ background-size: contain;
+ animation: cycling 2s infinite;
+ margin: -6px 0px 0px -2px;
+}
+@keyframes cycling {
+ from {
+ animation-timing-function: ease-in-out;
+ transform: translate(0px, 0px) scale(1, 1) rotate(0deg) skew(0deg, 0deg);
+ opacity: 1;
+ }
+
+ to {
+ animation-timing-function: ease-in-out;
+ transform: translate(0px, 0px) scale(1, 1) rotate(360deg) skew(0deg, 0deg);
+ opacity: 1;
+ }
+
+ 25% {
+ animation-timing-function: ease-in-out;
+ transform: translate(0px, 0px) scale(1, 1) rotate(400deg) skew(0deg, 0deg);
+ opacity: 1;
+ }
+
+ 40% {
+ animation-timing-function: ease-in-out;
+ transform: translate(0px, 0px) scale(1, 1) rotate(330deg) skew(0deg, 0deg);
+ opacity: 1;
+ }
+
+ 60% {
+ animation-timing-function: ease-in-out;
+ transform: translate(0px, 0px) scale(1, 1) rotate(360deg) skew(0deg, 0deg);
+ opacity: 1;
+ }
+}
+.rainbow {
+ animation: rain 5s infinite;
+}
+@keyframes rain {
+ 0% {
+ border: 1px solid magenta;
+ color: magenta;
+ }
+ 33% {
+ border: 1px solid yellow;
+ color: yellow;
+ }
+ 66% {
+ border: 1px solid cyan;
+ color: cyan;
+ }
+ 100% {
+ border: 1px solid magenta;
+ color: magenta;
+ }
+}
.userleftbox{
border-radius: 17px;
@@ -576,7 +652,7 @@ main h1{
color:var(--text-color);
text-decoration: none;
font-family: 'BIZ UDPGothic', sans-serif;
- font-weight: bold;
+ font-weight: normal;
}
.userheader .profile p img{
vertical-align: middle;
@@ -606,23 +682,12 @@ main h1{
.userheader .rolebox{
-
- margin-top: 0px;
- margin-bottom: 12px;
-
- margin-left: 0px;
- margin-right: 12px;
-
+ margin: 4px 6px 4px 6px;
width: auto;
padding-left: auto;
padding-right: auto;
-
- background-color: var(--background-color);
- border: 1px solid var(--main-color);
-
border-radius: 25px;
box-shadow:0 0px 48px 0 rgba(0, 0, 0, .15);
-
}
@@ -1132,6 +1197,7 @@ main h1{
padding-right: 6px;
padding-top: 3px;
padding-bottom: 3px;
+ background-color: #F5F5F5;
border: solid 1px #CCC;
color: #323232;
border-radius: 25px;
@@ -1319,6 +1385,7 @@ main h1{
width: 100%;
height: 350px;
border: 1px solid var(--border-color);
+ cursor: pointer;
}
.ueuse .photo2{
@@ -1334,6 +1401,7 @@ main h1{
width: 100%;
height: 350px;
border: 1px solid var(--border-color);
+ cursor: pointer;
}
.ueuse .photo3{
@@ -1353,6 +1421,7 @@ main h1{
width: 100%;
height: 200px;
border: 1px solid var(--border-color);
+ cursor: pointer;
}
.ueuse .photo3_btm a img{
object-fit: cover;
@@ -1363,6 +1432,7 @@ main h1{
min-width: 100%;
height: 200px;
border: 1px solid var(--border-color);
+ cursor: pointer;
}
.ueuse .photo4{
display: flex;
@@ -1377,6 +1447,7 @@ main h1{
width: 100%;
height: 200px;
border: 1px solid var(--border-color);
+ cursor: pointer;
}
.ueuse .video1 video{
object-fit: cover;
@@ -2079,6 +2150,16 @@ main h1{
font-size: 12px;
color:var(--main-color);
}
+.ueuse .flebox .user .u_name a img{
+ margin-top: 0px;
+ margin-bottom: 0px;
+ margin-left: 4px;
+ margin-right: 4px;
+ max-height: 22px;
+ width: auto;
+ vertical-align: text-top;
+ border-radius: 0px;
+}
.tokonone p{
@@ -2277,6 +2358,75 @@ main h1{
color: #FF4848;
}
+.sendbox .emoji_picker{
+ animation: Up_to_down_slideY 0.5s cubic-bezier(0.25, 1, 0.5, 1) 1 forwards;
+ margin-left: auto;
+ margin-right: auto;
+ margin-top: 24px;
+ margin-bottom: 0px;
+ border-radius: 10px;
+ padding-left: 12px;
+ padding-right: 12px;
+ padding-top: 16px;
+ padding-bottom: 16px;
+ background-color: var(--tl-color);
+ border: 1px solid var(--border-color);
+ width: auto;
+ max-height: 260px;
+ overflow-x: hidden;
+ overflow-y: scroll;
+}
+.sendbox .emoji_picker p{
+ margin: 0px;
+ word-wrap: break-word;
+ line-height: 20px;
+ color: var(--subtext-color);
+ font-size: 12px;
+ font-family: 'BIZ UDPGothic', sans-serif;
+ font-weight: normal;
+}
+.sendbox .emoji_picker .emoji_picker_flex{
+ display: flex;
+ flex-wrap: wrap;
+ justify-content: space-between;
+}
+.sendbox .emoji_picker .emoji_picker_flex .one_emoji{
+ cursor: pointer;
+ margin: 6px;
+ width: 64px;
+ height: 64px;
+ background-color: var(--tl-color);
+ border-radius: 8px;
+ transition: all 250ms ease-out;
+}
+.sendbox .emoji_picker .emoji_picker_flex .one_emoji img{
+ margin: 8px;
+ width: 48px;
+ height: 48px;
+ object-fit:contain;
+}
+.sendbox .emoji_picker .emoji_picker_flex .one_emoji:hover{
+ background-color: color-mix(in srgb, var(--tl-color) 95%, #000);
+}
+.sendbox .emoji_picker .tokonone p{
+ font-size: 16px;
+ color:var(--text-color);
+ text-decoration: none;
+ font-family: 'BIZ UDPGothic', sans-serif;
+ font-weight: bold;
+}
+@keyframes Up_to_down_slideY {
+ 0% {
+ transform: translateY(-12px);
+ opacity: 0;
+ }
+ 100% {
+ transform: translateY(0px);
+ }
+ 40%,100% {
+ opacity: 1;
+ }
+}
.ueusebtn{
cursor: pointer;
@@ -2880,6 +3030,48 @@ label>input {
}
}
+.Image_modal {
+ display: none;
+ position: fixed;
+ top: 0;
+ left: 0;
+ width: 100%;
+ height: 100%;
+ background-color: rgba(0, 0, 0, 0.25);
+ backdrop-filter: blur(5px);
+ z-index: 9999;
+ transition: all 250ms ease-out;
+}
+.Image_modal .modal-content {
+ padding: 0px;
+ border-radius: 15px;
+ width: fit-content;
+ height: fit-content;
+ max-width: 90%;
+ max-height: 90dvh;
+ position: absolute;
+ top: 30dvh;
+ right: 0;
+ bottom: 0;
+ left: 0;
+ margin: auto;
+ box-shadow:0 0px 48px 0 rgba(0, 0, 0, .15);
+ overflow: hidden;
+ cursor: zoom-out;
+}
+.Image_modal .modal-content img{
+ background: linear-gradient(45deg, #CCC 25%, transparent 25%, transparent 75%, #CCC 75%),
+ linear-gradient(45deg, #CCC 25%, transparent 25%, transparent 75%, #CCC 75%);
+ background-color: #FFF;
+ background-size: 20px 20px;
+ background-position: 0 0, 10px 10px;
+ width: 100%;
+ height: 80dvh;
+ margin: 0px;
+ vertical-align:top;
+ object-fit: contain;
+}
+
.topbox {
position: fixed;
@@ -3378,8 +3570,8 @@ label>input {
}
.emojibox{
- margin-left: 12px;
- margin-right: 12px;
+ margin-left: 0px;
+ margin-right: 0px;
padding: 12px;
width: auto;
}
@@ -3429,54 +3621,85 @@ label>input {
margin-bottom: 6px;
fill: currentColor;
}
-
-
-.emojizone{
- margin-left: 0px;
- margin-right: 0px;
- margin-top: 12px;
+.emojibox h1{
+ margin-left: 12px;
}
+.emojizone{
+ margin: 0px;
+ display: flex;
+ flex-wrap: wrap;
+ justify-content: space-between;
+ padding: 12px;
+ padding-top: 0px;
+}
+.emojizone .tokonone{
+ width: calc(50% - 32px);
+ height: fit-content;
+ margin-top: 0px;
+ margin-left: 0px;
+ margin-right: 0px;
+ margin-bottom: 12px;
+ padding: 12px;
+}
+.emojizone .tokonone p{
+ margin-top: 30px;
+ margin-bottom: 30px;
+}
.emjtex{
+ width: calc(50% - 32px);
background-color: var(--background-color);
- margin-top: 12px;
- margin-left: auto;
- margin-right: auto;
+ margin-top: 0px;
+ margin-left: 0px;
+ margin-right: 0px;
+ margin-bottom: 12px;
padding: 12px;
border-radius: 10px;
border: 1px solid var(--border-color);
+ transition: all 250ms ease-out;
+}
+.emjtex:hover{
+ background-color: color-mix(in srgb, var(--background-color) 95%, #000);
}
.emjtex .fx{
- display: block;
+ display: flex;
max-width: 100%;
+ flex-wrap: wrap;
+ justify-content: flex-start;
}
.emjtex img{
- margin-top: auto;
- margin-bottom: auto;
+ margin-top: 6px;
+ margin-bottom: 6px;
margin-left: 6px;
- margin-right: 4px;
+ margin-right: 6px;
max-height: 64px;
- max-width: 98%;
+ max-width: calc(100% - 12px);
+ object-fit: initial;
+}
+
+.emjtex .btm_zone{
+ margin-top: auto;
+ margin-bottom:auto;
}
.emjtex h3{
- overflow-wrap: break-word;
- margin-top: auto;
- margin-bottom: auto;
+ overflow-wrap: break-word;
+ margin-top: 6px;
+ margin-bottom: 6px;
margin-left: 6px;
font-size: 24px;
color:var(--text-color);
text-decoration: none;
- font-family: 'BIZ UDPGothic', sans-serif;
+ font-family: 'BIZ UDGothic', sans-serif;
font-weight: bold;
}
.emjtex p{
- overflow-wrap: break-word;
- margin-top: 12px;
- margin-bottom: auto;
+ overflow-wrap: break-word;
+ margin-top: 6px;
+ margin-bottom: 6px;
margin-left: 6px;
font-size: 16px;
color:var(--text-color);
@@ -3498,7 +3721,7 @@ label>input {
}
.this{
- background-color: var(--sub-color)!important;
+ background-color: color-mix(in srgb, var(--sub-color) 30%, var(--background-color))!important;
}
.notification{
animation: slideInY 0.5s cubic-bezier(0.25, 1, 0.5, 1) 1 forwards;
@@ -3562,6 +3785,12 @@ label>input {
font-family: 'BIZ UDPGothic', sans-serif;
font-weight: normal;
}
+.notification .flebox .username img{
+ margin-left: 6px;
+ margin-right: 6px;
+ width: 14px;
+ height: 14px;
+}
.notification .flebox .idbox{
margin-top: auto;
margin-bottom: auto;
@@ -4036,7 +4265,7 @@ hr{
font-weight: bold;
}
.hny .textmain{
- background-color: var(--border-color);
+ background-color: #F5F5F5;
padding-top: 8px;
padding-bottom: 8px;
padding-left: 24px;
@@ -4055,7 +4284,7 @@ hr{
}
.hny .textmain p{
text-align: left;
- color:var(--text-color);
+ color:#252525;
font-family: 'BIZ UDPGothic', sans-serif;
word-wrap: break-word;
font-size: 16px;
@@ -4064,7 +4293,7 @@ hr{
}
.hny .textmain .rp{
text-align: right;
- color:var(--text-color);
+ color:#252525;
font-family: 'BIZ UDPGothic', sans-serif;
word-wrap: break-word;
font-size: 14px;
@@ -4279,16 +4508,12 @@ summary {
font-weight: normal;
text-decoration:none;
text-align: center;
- transition: box-shadow 250ms ease-in-out;
- transition: width 250ms ease-out;
transition: all 250ms ease-out;
}
.delbox .delbtn:hover{
background-color: #FF4848;
color: var(--background-color);;
- transition: box-shadow 250ms ease-in-out;
- transition: width 250ms ease-out;
transition: all 250ms ease-out;
}
.mini_irobtn{
@@ -4311,15 +4536,11 @@ summary {
font-weight: normal;
text-decoration:none;
text-align: center;
- transition: box-shadow 250ms ease-in-out;
- transition: width 250ms ease-out;
transition: all 250ms ease-out;
}
.mini_irobtn:hover{
background-color: var(--main-color);
color: var(--background-color);;
- transition: box-shadow 250ms ease-in-out;
- transition: width 250ms ease-out;
transition: all 250ms ease-out;
}
@@ -4683,6 +4904,13 @@ summary {
.serverhead{
text-align: center;
}
+.formarea .serverhead img {
+ object-fit: cover;
+ width: 100%;
+ height: 220px;
+ border-radius: 10px;
+ margin: 0px;
+}
.serverhead img {
object-fit: cover;
width: 60%;
@@ -4833,6 +5061,116 @@ summary {
text-align: center;
}
+.graph{
+ margin-top: 12px;
+ margin-bottom: 12px;
+ margin-left: 0px;
+ margin-right: 0px;
+ width: 100%;
+ height: 32px;
+ background-color: var(--background-color);
+ border-radius: 50px;
+ border: solid 1px var(--border-color);
+}
+.graph .per{
+ margin-top: 4px;
+ margin-bottom: 4px;
+ margin-right: 4px;
+ margin-left: 4px;
+ height: 24px;
+ background-color: var(--main-color);
+ border-radius: 50px;
+ border: none;
+}
+
+noscript{
+ position: fixed;
+ top: 0;
+ left: 0;
+ width: 100%;
+ height: 100%;
+ background-color: rgba(0, 0, 0, 0.25);
+ backdrop-filter: blur(5px);
+ z-index: 9999;
+ transition: all 250ms ease-out;
+ cursor: not-allowed;
+}
+noscript .noscript_modal{
+ padding: 0px;
+ border-radius: 15px;
+ width: fit-content;
+ height: fit-content;
+ background-color: var(--background-color);
+ max-width: 50%;
+ max-height: 75dvh;
+ position: absolute;
+ top: 45%;
+ right: 0;
+ bottom: 45%;
+ left: 0;
+ margin: auto;
+ box-shadow:0 0px 48px 0 rgba(0, 0, 0, .15);
+ overflow: scroll;
+ cursor: auto;
+}
+noscript .noscript_modal .inner{
+ margin: 64px;
+}
+noscript .noscript_modal .inner .oops_icon{
+ margin-top: -32px;
+ font-family: 'BIZ UDPGothic', sans-serif;
+ font-size: 74px;
+ text-align: center;
+}
+noscript .noscript_modal .inner h1{
+ line-height: 32px;
+ font-family: 'BIZ UDPGothic', sans-serif;
+ font-size: 32px;
+ color:var(--text-color);
+ text-align: center;
+ font-weight: bold;
+}
+noscript .noscript_modal .inner p{
+ line-height: 20px;
+ font-family: 'BIZ UDPGothic', sans-serif;
+ font-size: 16px;
+ color:var(--text-color);
+ text-align: center;
+}
+noscript .noscript_modal .inner .p2{
+ margin-top: 12px;
+ text-align: center;
+}
+noscript .noscript_modal .inner .infobtn{
+ display: block;
+ width: 128px;
+ padding: 6px;
+ text-align: center;
+ margin-left: auto;
+ margin-right: auto;
+ display: block;
+ background-color:#FFC832;
+ color:#ffffff;
+ border-radius: 32px;
+ font-size: 20px;
+ font-family: 'BIZ UDGothic', 'Yu Mincho Regular', 'ヒラギノ角ゴシック', sans-serif;
+ font-weight: normal;
+ text-decoration: none;
+}
+noscript .noscript_modal .inner .center_text{
+ margin-top: 12px;
+ display: block;
+}
+noscript .noscript_modal .inner .center_text p{
+ line-height: 16px;
+ margin: 0px;
+ text-align: center;
+ color:#777;
+ font-size: 14px;
+ font-family: 'BIZ UDGothic', 'Yu Mincho Regular', 'ヒラギノ角ゴシック', sans-serif;
+ font-weight: normal;
+}
+
/*------------------------------------------------------------------------------------------------------------*/
/*--------------------------------------------------スマホ向け--------------------------------------------------*/
/*--------------------------------------------------ここから--------------------------------------------------*/
@@ -4874,8 +5212,8 @@ summary {
}
.userheader .roleboxes{
- margin-left: 12px;
- margin-right: 12px;
+ margin-left: 6px;
+ margin-right: 6px;
display: flex;
padding: 0px;
flex-wrap : wrap;
@@ -5036,6 +5374,19 @@ summary {
font-family: 'BIZ UDPGothic', sans-serif;
font-weight: bold;
}
+ .sendbox .emoji_picker .emoji_picker_flex{
+ justify-content: flex-start;
+ }
+ .sendbox .emoji_picker .emoji_picker_flex .one_emoji{
+ margin: 6px;
+ width: 40px;
+ height: 40px;
+ }
+ .sendbox .emoji_picker .emoji_picker_flex .one_emoji img{
+ margin: 3px;
+ width: 34px;
+ height: 34px;
+ }
.ueusebtn{
width:30%;
@@ -5920,6 +6271,40 @@ summary {
transform: translateY(-1%);
}
}
+ .Image_modal{
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
+ }
+ .Image_modal .modal-content {
+ padding: 0px;
+ border-radius: 15px;
+ width: fit-content;
+ height: fit-content;
+ max-width: 90%;
+ max-height: 90dvh;
+ position: absolute;
+ top: 45%;
+ right: 0;
+ bottom: 45%;
+ left: 0;
+ margin: auto;
+ margin-top: 0px;
+ margin-bottom: 0px;
+ box-shadow:0 0px 48px 0 rgba(0, 0, 0, .15);
+ overflow: hidden;
+ }
+ .Image_modal .modal-content img{
+ background: linear-gradient(45deg, #CCC 25%, transparent 25%, transparent 75%, #CCC 75%),
+ linear-gradient(45deg, #CCC 25%, transparent 25%, transparent 75%, #CCC 75%);
+ background-color: #FFF;
+ background-size: 20px 20px;
+ background-position: 0 0, 10px 10px;
+ width: 100%;
+ height: auto;
+ margin: 0px;
+ vertical-align:top;
+ object-fit: contain;
+ }
.tlchange{
border-radius: 10px;
@@ -6152,6 +6537,52 @@ summary {
border-radius: 10px;
margin: 0px;
}
+
+ noscript .noscript_modal{
+ border-radius: 15px;
+ max-width: 90%;
+ max-height: 90dvh;
+ overflow: scroll;
+ }
+ noscript .noscript_modal .inner{
+ margin: 24px;
+ }
+ noscript .noscript_modal .inner .oops_icon{
+ margin-top: 12px;
+ font-size: 48px;
+ }
+ noscript .noscript_modal .inner h1{
+ line-height: 24px;
+ font-size: 24px;
+ }
+ noscript .noscript_modal .inner p{
+ line-height: 16px;
+ font-size: 14px;
+ text-align: left;
+ }
+ noscript .noscript_modal .inner .center_text{
+ margin-top: 12px;
+ display: block;
+ }
+ noscript .noscript_modal .inner .center_text p{
+ line-height: 14px;
+ font-size: 12px;
+ }
+
+
+ .emojizone{
+ display: block;
+ }
+ .emjtex{
+ width: auto;
+ }
+ .emjtex .fx{
+ display: block;
+ }
+ .emojizone .tokonone{
+ width: auto;
+ height: fit-content;
+ }
}
/*------------------------------------------------------------------------------------------------------------*/
@@ -6161,6 +6592,11 @@ summary {
@media (prefers-color-scheme: dark) {
+ ::selection {
+ color: var(--dark-background-color);
+ background: var(--main-color);
+ }
+
body{
background-color: var(--dark-background-color);
}
@@ -6245,6 +6681,11 @@ summary {
background-color: var(--dark-ueuse-color);
color: var(--dark-text-color);
}
+ .ueuse .unixtime{
+ background-color: #323232;
+ border: solid 1px #CCC;
+ color: #F5F5F5;
+ }
.ueuse h1{
@@ -6574,12 +7015,32 @@ summary {
.sendbox .fxbox p{
color:var(--sub-color);
}
+
+ .sendbox .emoji_picker{
+ background-color: var(--dark-background-color);
+ border: none;
+ }
+ .sendbox .emoji_picker p{
+ color: var(--dark-subtext-color);
+ }
+ .sendbox .emoji_picker .emoji_picker_flex .one_emoji{
+ background-color: var(--dark-background-color);
+ }
+ .sendbox .emoji_picker .emoji_picker_flex .one_emoji:hover{
+ background-color: color-mix(in srgb, var(--dark-background-color) 95%, #FFF);
+ }
+ .sendbox .emoji_picker .tokonone p{
+ color:var(--dark-text-color);
+ }
.emjtex{
background-color: var(--dark-sub-color);
border: none;
}
+ .emjtex:hover{
+ background-color: color-mix(in srgb, var(--dark-sub-color) 95%, #FFF);
+ }
.emjtex h3{
color:var(--background-color);
@@ -6760,7 +7221,7 @@ summary {
}
.this{
- background-color: var(--link-color) !important;
+ background-color: color-mix(in srgb, var(--link-color) 30%, var(--dark-background-color))!important;
border: none !important;
}
@@ -7007,4 +7468,29 @@ summary {
background-color: #3a3333;
color: #ff4848;
}
+ .graph{
+ background-color: var(--dark-background-color);
+ border: solid 1px var(--dark-background-color);
+ }
+ .graph .per{
+ background-color: var(--main-color);
+ }
+ noscript .noscript_modal{
+ background-color: var(--dark-background-color);
+ }
+ noscript .noscript_modal .inner h1{
+ color:var(--dark-text-color);
+ }
+ noscript .noscript_modal .inner p{
+ color:var(--dark-text-color);
+ }
+ noscript .noscript_modal .inner .center_text p{
+ line-height: 16px;
+ margin: 0px;
+ text-align: center;
+ color:#CCC;
+ font-size: 14px;
+ font-family: 'BIZ UDGothic', 'Yu Mincho Regular', 'ヒラギノ角ゴシック', sans-serif;
+ font-weight: normal;
+ }
}
\ No newline at end of file
diff --git a/css/style.css b/css/style.css
index 45a2986..26a0c1d 100644
--- a/css/style.css
+++ b/css/style.css
@@ -414,8 +414,6 @@ label > input {
.formarea label{
overflow-wrap: break-word;
- margin-top: 24px;
- margin-bottom: 24px;
font-size: 16px;
color:var(--text-color);
text-decoration: none;
@@ -485,7 +483,7 @@ label > input {
transition: border 350ms ease-in-out;
transition: border-bottom 150ms ease-out;
border: 1px solid var(--border-color);
- }
+}
.inbox::placeholder {
color: #999;
@@ -592,40 +590,127 @@ label > input {
box-shadow:0 0px 48px 0 rgba(0, 0, 0, .05);
width:45%;
}
-.rolebox{
-
- margin-top: 12px;
- margin-bottom: 12px;
-
+.roleboxes {
margin-left: auto;
margin-right: auto;
+ max-width: 70%;
+ display: flex;
+ padding: auto;
+ flex-wrap: wrap;
+ justify-content: center;
+}
- width: 120px;
+.rolebox {
+ margin: 4px 6px 4px 6px;
+ width: auto;
padding-left: auto;
padding-right: auto;
-
- background-color: var(--background-color);
- border: 1px solid var(--main-color);
-
border-radius: 25px;
box-shadow:0 0px 48px 0 rgba(0, 0, 0, .15);
-
}
-
-.rolebox p{
-
- color:var(--main-color);
- margin-top: 2px;
- margin-bottom: 2px;
- margin-left: 10px;
- margin-right: 10px;
-
+
+.rolebox p {
+ margin: 2px 10px 2px 10px;
font-size: 16px;
- font-family: 'Zen Maru Gothic', sans-serif;
+ font-family: "Zen Maru Gothic", sans-serif;
font-weight: normal;
-
}
+.shine {
+ position: relative;
+ overflow: hidden;
+}
+.shine:after {
+ content: "";
+ position: absolute;
+ top: -50%;
+ left: -50%;
+ width: 10%;
+ height: 150%;
+ background: #fff;
+ transform: rotate(45deg);
+ animation: reflect 3s ease-in-out infinite;
+}
+@keyframes reflect {
+ 0%,
+ 75% {
+ transform: rotate(45deg) scale(0);
+ opacity: 1;
+ }
+
+ 100% {
+ transform: rotate(45deg) scale(100);
+ opacity: 0;
+ }
+}
+.cyclingmark {
+ display: flex;
+}
+.cyclingmark p::before {
+ content: "";
+ display: inline-block;
+ width: 16px;
+ height: 16px;
+ vertical-align: middle;
+ margin-right: 5px;
+ background: url("/img/uwuzuicon.png")
+ no-repeat;
+ background-size: contain;
+ animation: cycling 2s infinite;
+ margin: -6px 0px 0px -2px;
+}
+@keyframes cycling {
+ from {
+ animation-timing-function: ease-in-out;
+ transform: translate(0px, 0px) scale(1, 1) rotate(0deg) skew(0deg, 0deg);
+ opacity: 1;
+ }
+
+ to {
+ animation-timing-function: ease-in-out;
+ transform: translate(0px, 0px) scale(1, 1) rotate(360deg) skew(0deg, 0deg);
+ opacity: 1;
+ }
+
+ 25% {
+ animation-timing-function: ease-in-out;
+ transform: translate(0px, 0px) scale(1, 1) rotate(400deg) skew(0deg, 0deg);
+ opacity: 1;
+ }
+
+ 40% {
+ animation-timing-function: ease-in-out;
+ transform: translate(0px, 0px) scale(1, 1) rotate(330deg) skew(0deg, 0deg);
+ opacity: 1;
+ }
+
+ 60% {
+ animation-timing-function: ease-in-out;
+ transform: translate(0px, 0px) scale(1, 1) rotate(360deg) skew(0deg, 0deg);
+ opacity: 1;
+ }
+}
+.rainbow {
+ animation: rain 5s infinite;
+}
+@keyframes rain {
+ 0% {
+ border: 1px solid magenta;
+ color: magenta;
+ }
+ 33% {
+ border: 1px solid yellow;
+ color: yellow;
+ }
+ 66% {
+ border: 1px solid cyan;
+ color: cyan;
+ }
+ 100% {
+ border: 1px solid magenta;
+ color: magenta;
+ }
+}
.userleftbox{
margin-top: 0px;
@@ -810,6 +895,92 @@ p img{
text-align: left;
}
+
+.switch_input {
+ position: absolute;
+ left: 0;
+ top: 0;
+ width: 64%;
+ height: 64%;
+ z-index: 5;
+ opacity: 0;
+ cursor: pointer;
+}
+.switch_label {
+ margin-top: 0px;
+ margin-bottom: 0px;
+ width: 48px;
+ height: 24px;
+ background: var(--dark-subtext-color);
+ position: relative;
+ display: inline-block;
+ border-radius: 25px;
+ transition: 0.4s;
+ box-sizing: border-box;
+}
+.switch_label:after {
+ content: "";
+ position: absolute;
+ margin-top: 2px;
+ margin-left: 2px;
+ width: 20px;
+ height: 20px;
+ border-radius: 50%;
+ left: 0;
+ top: 0;
+ z-index: 2;
+ background: var(--background-color);
+ box-shadow: 0 0 5px rgba(0, 0, 0, 0.2);
+ transition: 0.2s;
+}
+.switch_input:checked + .switch_label {
+ background-color: var(--main-color);
+}
+.switch_input:checked + .switch_label:after {
+ left: 24px;
+}
+.switch_button {
+ position: relative;
+ width: 48px;
+ height: 24px;
+ margin-left: 0px;
+}
+.switch_flexbox{
+ display: flex;
+ margin-top: 12px;
+ margin-bottom: 12px;
+ height: fit-content;
+}
+.switch_flexbox p{
+ margin: 0px;
+ margin-top: 6px;
+ margin-left: 6px;
+ margin-right: 6px;
+ text-align: left;
+ word-wrap: break-word;
+ line-height: 14px;
+ color: var(--subtext-color);
+ font-size: 14px;
+ font-family: 'BIZ UDPGothic', sans-serif;
+ font-weight: normal;
+}
+.module_chk{
+ padding-top: 16px;
+ padding-bottom: 16px;
+ padding-left: 16px;
+ padding-right: 16px;
+ border-radius: 15px;
+ background-color: var(--background-color);
+ border: 1px solid var(--border-color);
+ margin-top: 12px;
+ text-align: left;
+ margin-left: auto;
+ margin-right: auto;
+}
+.module_chk p{
+ margin: 0px;
+ line-height: 24px;
+}
/*------------------------------------------------------------------------------------------------------------*/
/*--------------------------------------------------スマホ向け--------------------------------------------------*/
/*--------------------------------------------------ここから--------------------------------------------------*/
@@ -1073,6 +1244,7 @@ p img{
.btnbox{
background-color: var(--dark-sub-color);
+ border: none;
}
.irobutton{
background-color: var(--main-color);
@@ -1085,6 +1257,7 @@ p img{
.formarea{
background-color: var(--dark-sub-color);
+ border: none;
}
.formarea label{
color:var(--dark-text-color);
@@ -1132,4 +1305,7 @@ p img{
background-color: var(--main-color);
color: var(--dark-sub-color);
}
+ .errmsg p{
+ color:#ff4848;
+ }
}
\ No newline at end of file
diff --git a/emoji/index.php b/emoji/index.php
index c251e2a..6ea2f52 100644
--- a/emoji/index.php
+++ b/emoji/index.php
@@ -190,6 +190,11 @@ if (!empty($pdo)) {
require('../logout/logout.php');
+if(isset($_GET['q'])){
+ $keyword = htmlentities($_GET['q']);
+}else{
+ $keyword = "";
+}
// データベースの接続を閉じる
$pdo = null;
@@ -199,7 +204,7 @@ $pdo = null;
-
+
@@ -212,7 +217,7 @@ $pdo = null;
-
+
@@ -220,35 +225,125 @@ $pdo = null;
+
-
-
-
絵文字一覧
-
- ';
- echo '
';
- echo '

';
- echo '
:'.$value["emojiname"].':
';
- echo '
';
- echo '
'.$value["emojiinfo"].'
';
- echo '
';
- }
- }else{
- echo '
';
- }
- ?>
-
-
+
+
+
絵文字一覧
+
+
+
+
+
+
+
+
+
+ 🤔
+
+
+
エラー
+
サーバーの応答がなかったか不完全だったようです。
ネットワークの接続が正常かを確認の上再読み込みしてください。
(NETWORK_HUKANZEN_STOP)
+
+
+
+
\ No newline at end of file
diff --git a/errorpage/400.php b/errorpage/400.php
index 07caf74..31f2207 100644
--- a/errorpage/400.php
+++ b/errorpage/400.php
@@ -17,7 +17,7 @@ $domain = $_SERVER['HTTP_HOST'];
-
+
diff --git a/errorpage/401.php b/errorpage/401.php
index 20f879b..4b40bed 100644
--- a/errorpage/401.php
+++ b/errorpage/401.php
@@ -17,7 +17,7 @@ $domain = $_SERVER['HTTP_HOST'];
-
+
diff --git a/errorpage/403.php b/errorpage/403.php
index d306159..0c7aa5e 100644
--- a/errorpage/403.php
+++ b/errorpage/403.php
@@ -17,7 +17,7 @@ $domain = $_SERVER['HTTP_HOST'];
-
+
diff --git a/errorpage/404.php b/errorpage/404.php
index def5fb9..15c7310 100644
--- a/errorpage/404.php
+++ b/errorpage/404.php
@@ -19,7 +19,7 @@ $domain = $_SERVER['HTTP_HOST'];
-
+
diff --git a/errorpage/500.php b/errorpage/500.php
index 25e7cf9..312d8c8 100644
--- a/errorpage/500.php
+++ b/errorpage/500.php
@@ -16,7 +16,7 @@ $domain = $_SERVER['HTTP_HOST'];
-
+
diff --git a/errorpage/503.php b/errorpage/503.php
index 295fde3..9fa0278 100644
--- a/errorpage/503.php
+++ b/errorpage/503.php
@@ -22,7 +22,7 @@ $domain = $_SERVER['HTTP_HOST'];
-
+
diff --git a/errorpage/serverstop.php b/errorpage/serverstop.php
index 6ed2061..7651dc8 100644
--- a/errorpage/serverstop.php
+++ b/errorpage/serverstop.php
@@ -19,7 +19,7 @@ if(!empty(file_get_contents($serverstopfile))){
-
+
diff --git a/function/function.php b/function/function.php
index 9c2f160..01aaa6b 100644
--- a/function/function.php
+++ b/function/function.php
@@ -94,4 +94,209 @@ function check_mime_video($tmp_name){
return false;
}
}
+//文字装飾・URL変換など
+function processMarkdownAndWrapEmptyLines($markdownText){
+
+ //\___________________[注意]__________________\
+ // \____ここの順番を変えるとうまく動かなくなります___\
+ // \______Markdownうまく動くところを探すべし______\
+
+ $markdownText = preg_replace('/\[\[buruburu (.+)\]\]/m', '
$1', $markdownText);//ぶるぶる
+
+ $markdownText = preg_replace('/(^|[^`])`([^`\n]+)`($|[^`])/m', '$1
$2$3', $markdownText);//Inline Code
+
+ $markdownText = preg_replace_callback('/^\[\[time (\d+)\]\]/m', function($matches) {
+ $timestamp = $matches[1];
+ return '
' . date("Y/m/d H:i", htmlentities($timestamp, ENT_QUOTES, 'UTF-8', false)) . '';
+ }, $markdownText);
+
+ $markdownText = preg_replace('/\*\*\*(.*?)\*\*\*/', '
$1', $markdownText);//太字&斜体の全部のせセット
+ $markdownText = preg_replace('/\_\_\_(.*?)\_\_\_/', '
$1', $markdownText);//太字&斜体の全部のせセット
+
+ $markdownText = preg_replace('/\*\*(.*?)\*\*/', '
$1', $markdownText);//太字
+ $markdownText = preg_replace('/\_\_(.*?)\_\_/', '
$1', $markdownText);//太字
+
+ $markdownText = preg_replace('/\*(.*?)\*/', '
$1', $markdownText);//斜体
+ $markdownText = preg_replace('/\_(.*?)\_/', '
$1', $markdownText);//斜体
+
+ $markdownText = preg_replace('/\~\~(.*?)\~\~/m', '
$1', $markdownText);//打ち消し線
+
+ $markdownText = preg_replace('/>>> (.*)/m', '
$1', $markdownText);//>>> 引用
+
+ $markdownText = preg_replace('/\|\|(.*)\|\|/m', '
$1', $markdownText);//黒塗り
+
+ // タイトル(#、##、###)をHTMLのhタグに変換
+ $markdownText = preg_replace('/^# (.+)/m', '
$1
', $markdownText);
+ $markdownText = preg_replace('/^## (.+)/m', '
$1
', $markdownText);
+ $markdownText = preg_replace('/^### (.+)/m', '
$1
', $markdownText);
+
+ // 箇条書き(-)をHTMLのul/liタグに変換
+ $markdownText = preg_replace('/^- (.+)/m', '
・ $1
', $markdownText);
+
+ // 空行の前に何もない行をHTMLのpタグに変換
+ $markdownText = preg_replace('/(^\s*)(?!\s)(.*)/m', '$1
$2
', $markdownText);
+
+ return $markdownText;
+}
+//Profile
+function replaceProfileEmojiImages($postText) {
+ $postText = str_replace(''', '\'', $postText);
+ // プロフィール名で絵文字名(:emoji:)を検出して画像に置き換える
+ $emojiPattern = '/:(\w+):/';
+ $postTextWithImages = preg_replace_callback($emojiPattern, function($matches) {
+ $emojiName = $matches[1];
+ //絵文字path取得
+ $dbh = new PDO('mysql:charset=utf8mb4;dbname='.DB_NAME.';host='.DB_HOST, DB_USER, DB_PASS, array(
+ PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
+ PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC,
+ PDO::MYSQL_ATTR_USE_BUFFERED_QUERY => true,
+ ));
+ $emoji_Query = $dbh->prepare("SELECT emojifile, emojiname FROM emoji WHERE emojiname = :emojiname");
+ $emoji_Query->bindValue(':emojiname', $emojiName);
+ $emoji_Query->execute();
+ $emoji_row = $emoji_Query->fetch();
+ if(empty($emoji_row["emojifile"])){
+ $emoji_path = "img/sysimage/errorimage/emoji_404.png";
+ }else{
+ $emoji_path = $emoji_row["emojifile"];
+ }
+ return "

";
+ }, $postText);
+ return $postTextWithImages;
+}
+// ユーズ内の絵文字やhashtagを画像に置き換える
+function replaceEmojisWithImages($postText) {
+ $postText = str_replace(''', '\'', $postText);
+ // ユーズ内で絵文字名(:emoji:)を検出して画像に置き換える
+ $emojiPattern = '/:(\w+):/';
+ $postTextWithImages = preg_replace_callback($emojiPattern, function($matches) {
+ $emojiName = $matches[1];
+ //絵文字path取得
+ $dbh = new PDO('mysql:charset=utf8mb4;dbname='.DB_NAME.';host='.DB_HOST, DB_USER, DB_PASS, array(
+ PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
+ PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC,
+ PDO::MYSQL_ATTR_USE_BUFFERED_QUERY => true,
+ ));
+ $emoji_Query = $dbh->prepare("SELECT emojifile, emojiname FROM emoji WHERE emojiname = :emojiname");
+ $emoji_Query->bindValue(':emojiname', $emojiName);
+ $emoji_Query->execute();
+ $emoji_row = $emoji_Query->fetch();
+ if(empty($emoji_row["emojifile"])){
+ $emoji_path = "img/sysimage/errorimage/emoji_404.png";
+ }else{
+ $emoji_path = $emoji_row["emojifile"];
+ }
+ return "

";
+ }, $postText);
+
+ // @username を検出してリンクに置き換える
+ $usernamePattern = '/@(\w+)/';
+ $postTextWithImagesAndUsernames = preg_replace_callback($usernamePattern, function($matches) {
+ $username = $matches[1];
+
+ $dbh = new PDO('mysql:charset=utf8mb4;dbname='.DB_NAME.';host='.DB_HOST, DB_USER, DB_PASS, array(
+ PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
+ PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC,
+ PDO::MYSQL_ATTR_USE_BUFFERED_QUERY => true,
+ ));
+
+ $mentionsuserQuery = $dbh->prepare("SELECT username, userid FROM account WHERE userid = :userid");
+ $mentionsuserQuery->bindValue(':userid', $username);
+ $mentionsuserQuery->execute();
+ $mentionsuserData = $mentionsuserQuery->fetch();
+
+ if(empty($mentionsuserData)){
+ return "@$username";
+ }else{
+ return "
@".replaceProfileEmojiImages(htmlentities($mentionsuserData["username"], ENT_QUOTES, 'UTF-8', false))."";
+ }
+ }, $postTextWithImages);
+
+ $hashtagsPattern = '/#([\p{Han}\p{Hiragana}\p{Katakana}A-Za-z0-9ー_]+)/u';
+ $postTextWithHashtags = preg_replace_callback($hashtagsPattern, function($matches) {
+ $hashtags = $matches[1];
+ return "
" . '#' . $hashtags . "";
+ }, $postTextWithImagesAndUsernames);
+
+ return $postTextWithHashtags;
+}
+
+function replaceURLsWithLinks($postText, $maxLength = 48) {
+ $pattern = '/(https:\/\/[\w!?\/+\-_~;.,*&@#$%()+|https:\/\/[ぁ-んァ-ヶ一-龠々\w\-\/?=&%.]+)/';
+ $convertedText = preg_replace_callback($pattern, function($matches) use ($maxLength) {
+ $link = $matches[0];
+ $no_https_link = str_replace("https://", "", $link);
+ if (mb_strlen($link) > $maxLength) {
+ $truncatedLink = mb_substr($no_https_link, 0, $maxLength).'...';
+ return '
'.$truncatedLink.'';
+ } else {
+ return '
'.$no_https_link.'';
+ }
+ }, $postText);
+
+ return $convertedText;
+}
+function YouTube_and_nicovideo_Links($postText) {
+ // URLを正規表現を使って検出
+ $pattern = '/(https:\/\/[^\s<>\[\]\'"]+)/'; // 改良された正規表現
+ preg_match_all($pattern, $postText, $matches);
+
+ if(empty($url)){
+ $postText = "";
+ }
+
+ // 検出したURLごとに処理を行う
+ foreach ($matches[0] as $url) {
+ // ドメイン部分を抽出
+ $parsedUrl = parse_url($url);
+ if($parsedUrl['host'] == "youtube.com" || $parsedUrl['host'] == "youtu.be" || $parsedUrl['host'] == "www.youtube.com" || $parsedUrl['host'] == "m.youtube.com"){
+
+ if (isset($parsedUrl['query'])) {
+ if(false !== strpos($parsedUrl['query'], 'v=')) {
+ $video_id = str_replace('v=', '', htmlentities($parsedUrl['query'], ENT_QUOTES, 'UTF-8', false));
+ $iframe = true;
+ }else{
+ $video_id = str_replace('/', '', htmlentities($parsedUrl['path'], ENT_QUOTES, 'UTF-8', false));
+ $iframe = true;
+ }
+ $video_id = str_replace('&', '?', $video_id);
+ }elseif(isset($parsedUrl['path'])){
+ $video_id = str_replace('/', '', htmlentities($parsedUrl['path'], ENT_QUOTES, 'UTF-8', false));
+ $iframe = true;
+ }else{
+ $video_id = "";
+ $iframe = false;
+ }
+ // 不要な文字を削除してaタグを生成
+ if($iframe == true){
+ $link = '
';
+ }else{
+ $link = "";
+ }
+ // URLをドメインのみを表示するaタグで置き換え
+ $postText = $link;
+ }elseif($parsedUrl['host'] == "nicovideo.jp" || $parsedUrl['host'] == "www.nicovideo.jp"){
+
+ if(isset($parsedUrl['path'])){
+ $video_id = str_replace('/watch/', '', htmlentities($parsedUrl['path'], ENT_QUOTES, 'UTF-8', false));
+ $iframe = true;
+ }else{
+ $video_id = "";
+ $iframe = false;
+ }
+ // 不要な文字を削除してaタグを生成
+ if($iframe == true){
+ $link = '
@@ -740,9 +777,24 @@ if ("serviceWorker" in navigator) {
$('#moji_cnt').html(mojicount);
$('#ueusebtn').prop('disabled', true);
}
+ document.cookie = "ueuse=" + encodeURIComponent($(this).val()) + "; Secure; SameSite=Lax; path=/home;";
})
+ $("#emoji_picker_btn").click(function () {
+ if ($("#emoji_picker_btn").prop("checked") == true) {
+ $("#emoji_picker").show();
+ } else {
+ $("#emoji_picker").hide();
+ }
+ });
+ $(".one_emoji").click(function (event) {
+ event.preventDefault();
+ var children = $(this).children("img");
+ var custom_emojiname = children.attr("title");
+ $("#ueuse").val($("#ueuse").val() + custom_emojiname);
+ });
+
@@ -764,8 +816,8 @@ if ("serviceWorker" in navigator) {
@@ -776,18 +828,24 @@ if ("serviceWorker" in navigator) {
ユーズに追記しますか?
※追記は削除出来ません。
+
+
+
![]()
+
+
+
diff --git a/home/index.php b/home/index.php
index 79d35f8..c06d67c 100644
--- a/home/index.php
+++ b/home/index.php
@@ -3,7 +3,7 @@ $serversettings_file = "../server/serversettings.ini";
$serversettings = parse_ini_file($serversettings_file, true);
$mojisizefile = "../server/textsize.txt";
-$mojisize = (int)htmlspecialchars(file_get_contents($mojisizefile), ENT_QUOTES, 'UTF-8');
+$mojisize = (int)htmlentities(file_get_contents($mojisizefile), ENT_QUOTES, 'UTF-8');
//投稿及び返信レート制限↓(分):デフォで60件/分まで
$max_ueuse_rate_limit = 60;
@@ -190,7 +190,18 @@ $notificationcount = $notiData['notification_count'];
//-----------------URLから取得----------------
if(isset($_GET['text'])) {
- $ueuse = htmlspecialchars($_GET['text'], ENT_QUOTES, 'UTF-8', false);
+ $ueuse = htmlentities($_GET['text'], ENT_QUOTES, 'UTF-8', false);
+}elseif(isset($_COOKIE['ueuse'])) {
+ $ueuse = htmlentities($_COOKIE['ueuse'], ENT_QUOTES, 'UTF-8', false);
+}
+//-----------------絵文字の取得----------------
+if (!empty($pdo)) {
+ $custom_emoji_Query = "SELECT emojifile,emojiname,emojiinfo,emojidate FROM emoji ORDER BY emojidate DESC";
+ $custom_emoji_array = $pdo->query($custom_emoji_Query);
+
+ while ($row = $custom_emoji_array->fetch(PDO::FETCH_ASSOC)) {
+ $custom_emoji[] = $row;
+ }
}
//-------------------------------------------
@@ -222,10 +233,10 @@ function get_mentions_userid($postText) {
}
if( !empty($_POST['btn_submit']) ) {
- $ueuse = htmlspecialchars($_POST['ueuse'], ENT_QUOTES, 'UTF-8', false);
+ $ueuse = htmlentities($_POST['ueuse'], ENT_QUOTES, 'UTF-8', false);
if(isset($_POST['nsfw_chk'])){
- $nsfw_chk = htmlspecialchars($_POST['nsfw_chk'], ENT_QUOTES, 'UTF-8', false);
+ $nsfw_chk = htmlentities($_POST['nsfw_chk'], ENT_QUOTES, 'UTF-8', false);
}else{
$nsfw_chk = "false";
}
@@ -241,8 +252,8 @@ if( !empty($_POST['btn_submit']) ) {
$error_message[] = '内容を入力してください。(INPUT_PLEASE)';
} else {
// 文字数を確認
- if( (int)htmlspecialchars(file_get_contents($mojisizefile), ENT_QUOTES, 'UTF-8', false) < mb_strlen($ueuse, 'UTF-8') ) {
- $error_message[] = '内容は'.htmlspecialchars(file_get_contents($mojisizefile), ENT_QUOTES, 'UTF-8', false).'文字以内で入力してください。(INPUT_OVER_MAX_COUNT)';
+ if( (int)htmlentities(file_get_contents($mojisizefile), ENT_QUOTES, 'UTF-8', false) < mb_strlen($ueuse, 'UTF-8') ) {
+ $error_message[] = '内容は'.htmlentities(file_get_contents($mojisizefile), ENT_QUOTES, 'UTF-8', false).'文字以内で入力してください。(INPUT_OVER_MAX_COUNT)';
}
// 禁止url確認
@@ -476,6 +487,8 @@ if( !empty($_POST['btn_submit']) ) {
}
if( empty($error_message) ) {
+ //一時保存していたユーズ内容の削除
+ setcookie("ueuse", "", time() - 30);
// 書き込み日時を取得
$datetime = date("Y-m-d H:i:s");
@@ -490,21 +503,21 @@ if( !empty($_POST['btn_submit']) ) {
// SQL作成
$stmt = $pdo->prepare("INSERT INTO ueuse (username, account, uniqid, ueuse, photo1, photo2, photo3, photo4, video1, datetime, abi, nsfw) VALUES (:username, :account, :uniqid, :ueuse, :photo1, :photo2, :photo3, :photo4, :video1, :datetime, :abi, :nsfw)");
- $stmt->bindParam(':username', htmlspecialchars($username, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
- $stmt->bindParam(':account', htmlspecialchars($userid, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
- $stmt->bindParam(':uniqid', htmlspecialchars($uniqid, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
- $stmt->bindParam(':ueuse', htmlspecialchars($ueuse, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
+ $stmt->bindParam(':username', htmlentities($username, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
+ $stmt->bindParam(':account', htmlentities($userid, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
+ $stmt->bindParam(':uniqid', htmlentities($uniqid, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
+ $stmt->bindParam(':ueuse', htmlentities($ueuse, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
- $stmt->bindParam(':photo1', htmlspecialchars($photo1, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
- $stmt->bindParam(':photo2', htmlspecialchars($photo2, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
- $stmt->bindParam(':photo3', htmlspecialchars($photo3, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
- $stmt->bindParam(':photo4', htmlspecialchars($photo4, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
- $stmt->bindParam(':video1', htmlspecialchars($video1, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
- $stmt->bindParam(':datetime', htmlspecialchars($datetime, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
+ $stmt->bindParam(':photo1', htmlentities($photo1, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
+ $stmt->bindParam(':photo2', htmlentities($photo2, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
+ $stmt->bindParam(':photo3', htmlentities($photo3, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
+ $stmt->bindParam(':photo4', htmlentities($photo4, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
+ $stmt->bindParam(':video1', htmlentities($video1, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
+ $stmt->bindParam(':datetime', htmlentities($datetime, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
- $stmt->bindParam(':nsfw', htmlspecialchars($save_nsfw, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
+ $stmt->bindParam(':nsfw', htmlentities($save_nsfw, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
- $stmt->bindParam(':abi', htmlspecialchars($abi, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
+ $stmt->bindParam(':abi', htmlentities($abi, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
// SQLクエリの実行
$res = $stmt->execute();
@@ -524,21 +537,21 @@ if( !empty($_POST['btn_submit']) ) {
$datetime = date("Y-m-d H:i:s");
$msg = "" . $ueuse . "";
$title = "" . $userid . "さんにメンションされました!";
- $url = "/!" . $uniqid . "~" . $userid . "";
+ $url = "/!" . $uniqid . "";
$userchk = 'none';
// 通知用SQL作成
$stmt = $pdo->prepare("INSERT INTO notification (fromuserid, touserid, msg, url, datetime, userchk, title) VALUES (:fromuserid, :touserid, :msg, :url, :datetime, :userchk, :title)");
- $stmt->bindParam(':fromuserid', htmlspecialchars($fromuserid, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
- $stmt->bindParam(':touserid', htmlspecialchars($touserid, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
- $stmt->bindParam(':msg', htmlspecialchars($msg, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
- $stmt->bindParam(':url', htmlspecialchars($url, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
- $stmt->bindParam(':userchk', htmlspecialchars($userchk, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
- $stmt->bindParam(':title', htmlspecialchars($title, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
+ $stmt->bindParam(':fromuserid', htmlentities($fromuserid, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
+ $stmt->bindParam(':touserid', htmlentities($touserid, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
+ $stmt->bindParam(':msg', htmlentities($msg, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
+ $stmt->bindParam(':url', htmlentities($url, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
+ $stmt->bindParam(':userchk', htmlentities($userchk, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
+ $stmt->bindParam(':title', htmlentities($title, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
- $stmt->bindParam(':datetime', htmlspecialchars($datetime, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
+ $stmt->bindParam(':datetime', htmlentities($datetime, ENT_QUOTES, 'UTF-8', false), PDO::PARAM_STR);
// SQLクエリの実行
$res = $stmt->execute();
@@ -590,7 +603,7 @@ $pdo = null;
-
+
@@ -608,7 +621,7 @@ if ("serviceWorker" in navigator) {
-ローカルタイムライン -
+ローカルタイムライン -
@@ -674,7 +687,7 @@ if ("serviceWorker" in navigator) {
@@ -769,7 +805,21 @@ if ("serviceWorker" in navigator) {
$('#moji_cnt').html(mojicount);
$('#ueusebtn').prop('disabled', true);
}
+ document.cookie = "ueuse=" + encodeURIComponent($(this).val()) + "; Secure; SameSite=Lax; path=/home;";
})
+ $("#emoji_picker_btn").click(function () {
+ if ($("#emoji_picker_btn").prop("checked") == true) {
+ $("#emoji_picker").show();
+ } else {
+ $("#emoji_picker").hide();
+ }
+ });
+ $(".one_emoji").click(function (event) {
+ event.preventDefault();
+ var children = $(this).children("img");
+ var custom_emojiname = children.attr("title");
+ $("#ueuse").val($("#ueuse").val() + custom_emojiname);
+ });
@@ -793,8 +843,8 @@ if ("serviceWorker" in navigator) {
@@ -805,18 +855,25 @@ if ("serviceWorker" in navigator) {
ユーズに追記しますか?
※追記は削除出来ません。
+
+
+
![]()
+
+
+
+
diff --git a/index.php b/index.php
index 42badbd..9ef0106 100644
--- a/index.php
+++ b/index.php
@@ -121,6 +121,7 @@ $count2 = $result2->num_rows;
+
diff --git a/js/back.js b/js/back.js
index 671e6cd..fec194c 100644
--- a/js/back.js
+++ b/js/back.js
@@ -1,8 +1,8 @@
-window.onload = function(){
-var url = new URL(window.location.href);
+window.onload = function () {
+ var url = new URL(window.location.href);
-var ele = document.getElementsByTagName("body")[0];
-var n = Math.floor(Math.random() * 3); // 3枚の画像がある場合
-ele.style.backgroundImage = "url("+url.protocol+"//"+url.hostname+"/img/titleimg/"+n+".png)";
+ var ele = document.getElementsByTagName("body")[0];
+ var n = Math.floor(Math.random() * 3); // 3枚の画像がある場合
+ ele.style.backgroundImage = "url(" + url.protocol + "//" + url.hostname + "/img/titleimg/" + n + ".png)";
}
diff --git a/js/jquery-min.js b/js/jquery-min.js
new file mode 100644
index 0000000..7f37b5d
--- /dev/null
+++ b/js/jquery-min.js
@@ -0,0 +1,2 @@
+/*! jQuery v3.7.1 | (c) OpenJS Foundation and other contributors | jquery.org/license */
+!function(e,t){"use strict";"object"==typeof module&&"object"==typeof module.exports?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(ie,e){"use strict";var oe=[],r=Object.getPrototypeOf,ae=oe.slice,g=oe.flat?function(e){return oe.flat.call(e)}:function(e){return oe.concat.apply([],e)},s=oe.push,se=oe.indexOf,n={},i=n.toString,ue=n.hasOwnProperty,o=ue.toString,a=o.call(Object),le={},v=function(e){return"function"==typeof e&&"number"!=typeof e.nodeType&&"function"!=typeof e.item},y=function(e){return null!=e&&e===e.window},C=ie.document,u={type:!0,src:!0,nonce:!0,noModule:!0};function m(e,t,n){var r,i,o=(n=n||C).createElement("script");if(o.text=e,t)for(r in u)(i=t[r]||t.getAttribute&&t.getAttribute(r))&&o.setAttribute(r,i);n.head.appendChild(o).parentNode.removeChild(o)}function x(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?n[i.call(e)]||"object":typeof e}var t="3.7.1",l=/HTML$/i,ce=function(e,t){return new ce.fn.init(e,t)};function c(e){var t=!!e&&"length"in e&&e.length,n=x(e);return!v(e)&&!y(e)&&("array"===n||0===t||"number"==typeof t&&0+~]|"+ge+")"+ge+"*"),x=new RegExp(ge+"|>"),j=new RegExp(g),A=new RegExp("^"+t+"$"),D={ID:new RegExp("^#("+t+")"),CLASS:new RegExp("^\\.("+t+")"),TAG:new RegExp("^("+t+"|[*])"),ATTR:new RegExp("^"+p),PSEUDO:new RegExp("^"+g),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+ge+"*(even|odd|(([+-]|)(\\d*)n|)"+ge+"*(?:([+-]|)"+ge+"*(\\d+)|))"+ge+"*\\)|)","i"),bool:new RegExp("^(?:"+f+")$","i"),needsContext:new RegExp("^"+ge+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+ge+"*((?:-\\d)?\\d*)"+ge+"*\\)|)(?=[^-]|$)","i")},N=/^(?:input|select|textarea|button)$/i,q=/^h\d$/i,L=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,H=/[+~]/,O=new RegExp("\\\\[\\da-fA-F]{1,6}"+ge+"?|\\\\([^\\r\\n\\f])","g"),P=function(e,t){var n="0x"+e.slice(1)-65536;return t||(n<0?String.fromCharCode(n+65536):String.fromCharCode(n>>10|55296,1023&n|56320))},M=function(){V()},R=J(function(e){return!0===e.disabled&&fe(e,"fieldset")},{dir:"parentNode",next:"legend"});try{k.apply(oe=ae.call(ye.childNodes),ye.childNodes),oe[ye.childNodes.length].nodeType}catch(e){k={apply:function(e,t){me.apply(e,ae.call(t))},call:function(e){me.apply(e,ae.call(arguments,1))}}}function I(t,e,n,r){var i,o,a,s,u,l,c,f=e&&e.ownerDocument,p=e?e.nodeType:9;if(n=n||[],"string"!=typeof t||!t||1!==p&&9!==p&&11!==p)return n;if(!r&&(V(e),e=e||T,C)){if(11!==p&&(u=L.exec(t)))if(i=u[1]){if(9===p){if(!(a=e.getElementById(i)))return n;if(a.id===i)return k.call(n,a),n}else if(f&&(a=f.getElementById(i))&&I.contains(e,a)&&a.id===i)return k.call(n,a),n}else{if(u[2])return k.apply(n,e.getElementsByTagName(t)),n;if((i=u[3])&&e.getElementsByClassName)return k.apply(n,e.getElementsByClassName(i)),n}if(!(h[t+" "]||d&&d.test(t))){if(c=t,f=e,1===p&&(x.test(t)||m.test(t))){(f=H.test(t)&&U(e.parentNode)||e)==e&&le.scope||((s=e.getAttribute("id"))?s=ce.escapeSelector(s):e.setAttribute("id",s=S)),o=(l=Y(t)).length;while(o--)l[o]=(s?"#"+s:":scope")+" "+Q(l[o]);c=l.join(",")}try{return k.apply(n,f.querySelectorAll(c)),n}catch(e){h(t,!0)}finally{s===S&&e.removeAttribute("id")}}}return re(t.replace(ve,"$1"),e,n,r)}function W(){var r=[];return function e(t,n){return r.push(t+" ")>b.cacheLength&&delete e[r.shift()],e[t+" "]=n}}function F(e){return e[S]=!0,e}function $(e){var t=T.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function B(t){return function(e){return fe(e,"input")&&e.type===t}}function _(t){return function(e){return(fe(e,"input")||fe(e,"button"))&&e.type===t}}function z(t){return function(e){return"form"in e?e.parentNode&&!1===e.disabled?"label"in e?"label"in e.parentNode?e.parentNode.disabled===t:e.disabled===t:e.isDisabled===t||e.isDisabled!==!t&&R(e)===t:e.disabled===t:"label"in e&&e.disabled===t}}function X(a){return F(function(o){return o=+o,F(function(e,t){var n,r=a([],e.length,o),i=r.length;while(i--)e[n=r[i]]&&(e[n]=!(t[n]=e[n]))})})}function U(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}function V(e){var t,n=e?e.ownerDocument||e:ye;return n!=T&&9===n.nodeType&&n.documentElement&&(r=(T=n).documentElement,C=!ce.isXMLDoc(T),i=r.matches||r.webkitMatchesSelector||r.msMatchesSelector,r.msMatchesSelector&&ye!=T&&(t=T.defaultView)&&t.top!==t&&t.addEventListener("unload",M),le.getById=$(function(e){return r.appendChild(e).id=ce.expando,!T.getElementsByName||!T.getElementsByName(ce.expando).length}),le.disconnectedMatch=$(function(e){return i.call(e,"*")}),le.scope=$(function(){return T.querySelectorAll(":scope")}),le.cssHas=$(function(){try{return T.querySelector(":has(*,:jqfake)"),!1}catch(e){return!0}}),le.getById?(b.filter.ID=function(e){var t=e.replace(O,P);return function(e){return e.getAttribute("id")===t}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&C){var n=t.getElementById(e);return n?[n]:[]}}):(b.filter.ID=function(e){var n=e.replace(O,P);return function(e){var t="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return t&&t.value===n}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&C){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode("id"))&&n.value===e)return[o];i=t.getElementsByName(e),r=0;while(o=i[r++])if((n=o.getAttributeNode("id"))&&n.value===e)return[o]}return[]}}),b.find.TAG=function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):t.querySelectorAll(e)},b.find.CLASS=function(e,t){if("undefined"!=typeof t.getElementsByClassName&&C)return t.getElementsByClassName(e)},d=[],$(function(e){var t;r.appendChild(e).innerHTML="",e.querySelectorAll("[selected]").length||d.push("\\["+ge+"*(?:value|"+f+")"),e.querySelectorAll("[id~="+S+"-]").length||d.push("~="),e.querySelectorAll("a#"+S+"+*").length||d.push(".#.+[+~]"),e.querySelectorAll(":checked").length||d.push(":checked"),(t=T.createElement("input")).setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),r.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&d.push(":enabled",":disabled"),(t=T.createElement("input")).setAttribute("name",""),e.appendChild(t),e.querySelectorAll("[name='']").length||d.push("\\["+ge+"*name"+ge+"*="+ge+"*(?:''|\"\")")}),le.cssHas||d.push(":has"),d=d.length&&new RegExp(d.join("|")),l=function(e,t){if(e===t)return a=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n||(1&(n=(e.ownerDocument||e)==(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!le.sortDetached&&t.compareDocumentPosition(e)===n?e===T||e.ownerDocument==ye&&I.contains(ye,e)?-1:t===T||t.ownerDocument==ye&&I.contains(ye,t)?1:o?se.call(o,e)-se.call(o,t):0:4&n?-1:1)}),T}for(e in I.matches=function(e,t){return I(e,null,null,t)},I.matchesSelector=function(e,t){if(V(e),C&&!h[t+" "]&&(!d||!d.test(t)))try{var n=i.call(e,t);if(n||le.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){h(t,!0)}return 0":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(O,P),e[3]=(e[3]||e[4]||e[5]||"").replace(O,P),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||I.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&I.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return D.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&j.test(n)&&(t=Y(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(O,P).toLowerCase();return"*"===e?function(){return!0}:function(e){return fe(e,t)}},CLASS:function(e){var t=s[e+" "];return t||(t=new RegExp("(^|"+ge+")"+e+"("+ge+"|$)"))&&s(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(n,r,i){return function(e){var t=I.attr(e,n);return null==t?"!="===r:!r||(t+="","="===r?t===i:"!="===r?t!==i:"^="===r?i&&0===t.indexOf(i):"*="===r?i&&-1:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function T(e,n,r){return v(n)?ce.grep(e,function(e,t){return!!n.call(e,t,e)!==r}):n.nodeType?ce.grep(e,function(e){return e===n!==r}):"string"!=typeof n?ce.grep(e,function(e){return-1)[^>]*|#([\w-]+))$/;(ce.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||k,"string"==typeof e){if(!(r="<"===e[0]&&">"===e[e.length-1]&&3<=e.length?[null,e,null]:S.exec(e))||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof ce?t[0]:t,ce.merge(this,ce.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:C,!0)),w.test(r[1])&&ce.isPlainObject(t))for(r in t)v(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=C.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):v(e)?void 0!==n.ready?n.ready(e):e(ce):ce.makeArray(e,this)}).prototype=ce.fn,k=ce(C);var E=/^(?:parents|prev(?:Until|All))/,j={children:!0,contents:!0,next:!0,prev:!0};function A(e,t){while((e=e[t])&&1!==e.nodeType);return e}ce.fn.extend({has:function(e){var t=ce(e,this),n=t.length;return this.filter(function(){for(var e=0;e\x20\t\r\n\f]*)/i,Ce=/^$|^module$|\/(?:java|ecma)script/i;xe=C.createDocumentFragment().appendChild(C.createElement("div")),(be=C.createElement("input")).setAttribute("type","radio"),be.setAttribute("checked","checked"),be.setAttribute("name","t"),xe.appendChild(be),le.checkClone=xe.cloneNode(!0).cloneNode(!0).lastChild.checked,xe.innerHTML="",le.noCloneChecked=!!xe.cloneNode(!0).lastChild.defaultValue,xe.innerHTML="",le.option=!!xe.lastChild;var ke={thead:[1,""],col:[2,""],tr:[2,""],td:[3,""],_default:[0,"",""]};function Se(e,t){var n;return n="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&fe(e,t)?ce.merge([e],n):n}function Ee(e,t){for(var n=0,r=e.length;n",""]);var je=/<|?\w+;/;function Ae(e,t,n,r,i){for(var o,a,s,u,l,c,f=t.createDocumentFragment(),p=[],d=0,h=e.length;d\s*$/g;function Re(e,t){return fe(e,"table")&&fe(11!==t.nodeType?t:t.firstChild,"tr")&&ce(e).children("tbody")[0]||e}function Ie(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function We(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function Fe(e,t){var n,r,i,o,a,s;if(1===t.nodeType){if(_.hasData(e)&&(s=_.get(e).events))for(i in _.remove(t,"handle events"),s)for(n=0,r=s[i].length;n").attr(n.scriptAttrs||{}).prop({charset:n.scriptCharset,src:n.url}).on("load error",i=function(e){r.remove(),i=null,e&&t("error"===e.type?404:200,e.type)}),C.head.appendChild(r[0])},abort:function(){i&&i()}}});var Jt,Kt=[],Zt=/(=)\?(?=&|$)|\?\?/;ce.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=Kt.pop()||ce.expando+"_"+jt.guid++;return this[e]=!0,e}}),ce.ajaxPrefilter("json jsonp",function(e,t,n){var r,i,o,a=!1!==e.jsonp&&(Zt.test(e.url)?"url":"string"==typeof e.data&&0===(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&Zt.test(e.data)&&"data");if(a||"jsonp"===e.dataTypes[0])return r=e.jsonpCallback=v(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,a?e[a]=e[a].replace(Zt,"$1"+r):!1!==e.jsonp&&(e.url+=(At.test(e.url)?"&":"?")+e.jsonp+"="+r),e.converters["script json"]=function(){return o||ce.error(r+" was not called"),o[0]},e.dataTypes[0]="json",i=ie[r],ie[r]=function(){o=arguments},n.always(function(){void 0===i?ce(ie).removeProp(r):ie[r]=i,e[r]&&(e.jsonpCallback=t.jsonpCallback,Kt.push(r)),o&&v(i)&&i(o[0]),o=i=void 0}),"script"}),le.createHTMLDocument=((Jt=C.implementation.createHTMLDocument("").body).innerHTML="",2===Jt.childNodes.length),ce.parseHTML=function(e,t,n){return"string"!=typeof e?[]:("boolean"==typeof t&&(n=t,t=!1),t||(le.createHTMLDocument?((r=(t=C.implementation.createHTMLDocument("")).createElement("base")).href=C.location.href,t.head.appendChild(r)):t=C),o=!n&&[],(i=w.exec(e))?[t.createElement(i[1])]:(i=Ae([e],t,o),o&&o.length&&ce(o).remove(),ce.merge([],i.childNodes)));var r,i,o},ce.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(" ");return-1").append(ce.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this},ce.expr.pseudos.animated=function(t){return ce.grep(ce.timers,function(e){return t===e.elem}).length},ce.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l=ce.css(e,"position"),c=ce(e),f={};"static"===l&&(e.style.position="relative"),s=c.offset(),o=ce.css(e,"top"),u=ce.css(e,"left"),("absolute"===l||"fixed"===l)&&-1<(o+u).indexOf("auto")?(a=(r=c.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),v(t)&&(t=t.call(e,n,ce.extend({},s))),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+i),"using"in t?t.using.call(e,f):c.css(f)}},ce.fn.extend({offset:function(t){if(arguments.length)return void 0===t?this:this.each(function(e){ce.offset.setOffset(this,t,e)});var e,n,r=this[0];return r?r.getClientRects().length?(e=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:e.top+n.pageYOffset,left:e.left+n.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var e,t,n,r=this[0],i={top:0,left:0};if("fixed"===ce.css(r,"position"))t=r.getBoundingClientRect();else{t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;while(e&&(e===n.body||e===n.documentElement)&&"static"===ce.css(e,"position"))e=e.parentNode;e&&e!==r&&1===e.nodeType&&((i=ce(e).offset()).top+=ce.css(e,"borderTopWidth",!0),i.left+=ce.css(e,"borderLeftWidth",!0))}return{top:t.top-i.top-ce.css(r,"marginTop",!0),left:t.left-i.left-ce.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent;while(e&&"static"===ce.css(e,"position"))e=e.offsetParent;return e||J})}}),ce.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(t,i){var o="pageYOffset"===i;ce.fn[t]=function(e){return M(this,function(e,t,n){var r;if(y(e)?r=e:9===e.nodeType&&(r=e.defaultView),void 0===n)return r?r[i]:e[t];r?r.scrollTo(o?r.pageXOffset:n,o?n:r.pageYOffset):e[t]=n},t,e,arguments.length)}}),ce.each(["top","left"],function(e,n){ce.cssHooks[n]=Ye(le.pixelPosition,function(e,t){if(t)return t=Ge(e,n),_e.test(t)?ce(e).position()[n]+"px":t})}),ce.each({Height:"height",Width:"width"},function(a,s){ce.each({padding:"inner"+a,content:s,"":"outer"+a},function(r,o){ce.fn[o]=function(e,t){var n=arguments.length&&(r||"boolean"!=typeof e),i=r||(!0===e||!0===t?"margin":"border");return M(this,function(e,t,n){var r;return y(e)?0===o.indexOf("outer")?e["inner"+a]:e.document.documentElement["client"+a]:9===e.nodeType?(r=e.documentElement,Math.max(e.body["scroll"+a],r["scroll"+a],e.body["offset"+a],r["offset"+a],r["client"+a])):void 0===n?ce.css(e,t,i):ce.style(e,t,n,i)},s,n?e:void 0,n)}})}),ce.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){ce.fn[t]=function(e){return this.on(t,e)}}),ce.fn.extend({bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)},hover:function(e,t){return this.on("mouseenter",e).on("mouseleave",t||e)}}),ce.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,n){ce.fn[n]=function(e,t){return 0= 6.0) {
+ var iosv = (RegExp.$1.replace(/_/g, '.')).slice(0, 4);
+ if (iosv >= 6.0) {
user_agent_os = "iOS_6_Over";
} else {
user_agent_os = "iOS_6_Under";
}
} else if (ua.match(/Linux/)) {
- user_agent_os = "Linux";
-} else if(ua.indexOf("ipad") !== -1 || ua.indexOf("Mac OS X") !== -1 && typeof document.ontouchstart !== 'undefined') {
+ user_agent_os = "Linux";
+} else if (ua.indexOf("ipad") !== -1 || ua.indexOf("Mac OS X") !== -1 && typeof document.ontouchstart !== 'undefined') {
user_agent_os = "iPad";
-} else if(ua.indexOf("Mac OS X") !== -1) {
+} else if (ua.indexOf("Mac OS X") !== -1) {
user_agent_os = "mac_OS";
} else if (ua.match(/^.*\s([A-Za-z]+BSD)/)) {
- user_agent_os = RegExp.$1;
+ user_agent_os = RegExp.$1;
} else if (ua.match(/SunOS/)) {
- user_agent_os = "Solaris";
+ user_agent_os = "Solaris";
} else if (ua.match("Nintendo Wii")) {
- user_agent_os = "Nintendo_Wii";
+ user_agent_os = "Nintendo_Wii";
} else if (ua.match("PlayStation 4")) {
- user_agent_os = "SONY_PS4";
+ user_agent_os = "SONY_PS4";
} else if (ua.match("PlayStation 5")) {
- user_agent_os = "SONY_PS5";
+ user_agent_os = "SONY_PS5";
} else if (ua.match("PlayStation Vita")) {
- user_agent_os = "SONY_PSVita";
+ user_agent_os = "SONY_PSVita";
} else if (ua.match("Nintendo Switch")) {
- user_agent_os = "Nintendo_Switch";
+ user_agent_os = "Nintendo_Switch";
} else if (ua.match("Windows Phone")) {
- user_agent_os = "Windows_Phone";
+ user_agent_os = "Windows_Phone";
} else {
user_agent_os = 'Other';
}
/*SSL*/
if (location.protocol == 'http:') {
- if (location.hostname == 'localhost'){
+ if (location.hostname == 'localhost') {
user_agent_ssl = "not_ssl";
- }else{
+ } else {
user_agent_ssl = "not_ssl_bad";
}
} else if (location.protocol == 'https:') {
- user_agent_ssl = "ssl";
+ user_agent_ssl = "ssl";
} else {
user_agent_ssl = "Other";
}
/*Cookie*/
if (navigator.cookieEnabled) {
- user_agent_cookie = 'cookie_on';
+ user_agent_cookie = 'cookie_on';
} else {
- user_agent_cookie = 'cookie_off';
+ user_agent_cookie = 'cookie_off';
}
/*Main Access check*/
@@ -96,7 +96,7 @@ if (user_agent_browser == 'Microsoft_Internet_Explorer' || user_agent_browser ==
} else if (user_agent_ssl == 'not_ssl_bad') {
user_agent_access = 'bad';
errcode = 'NONE_SSL_SERVER';
-}else{
+} else {
user_agent_access = 'ok';
errcode = 'NONE_ERROR';
}
@@ -110,10 +110,10 @@ console.log('access : '+user_agent_access);
console.log('errorcode : '+errcode);
*/
-if (user_agent_access == 'bad'){
+if (user_agent_access == 'bad') {
setTimeout(link(), 0);
- function link(){
- location.href="../unsupported.php?errcode="+errcode+"&browser="+user_agent_browser+"&os="+user_agent_os+"&cookie="+user_agent_cookie+"&ssl="+user_agent_ssl+""
+ function link() {
+ location.href = "../unsupported.php?errcode=" + errcode + "&browser=" + user_agent_browser + "&os=" + user_agent_os + "&cookie=" + user_agent_cookie + "&ssl=" + user_agent_ssl + ""
}
}
diff --git a/language/ja-jp.json b/language/ja-jp.json
new file mode 100644
index 0000000..7603df0
--- /dev/null
+++ b/language/ja-jp.json
@@ -0,0 +1,46 @@
+{
+ "lang_name" : "日本語",
+
+ "uwuzu" : "ゆず",
+ "home" : "ホーム",
+ "search" : "検索",
+ "notification" : "通知",
+ "emoji" : "絵文字",
+ "profile" : "プロフィール",
+ "settings" : "設定",
+ "others" : "その他",
+ "add_emoji" : "絵文字登録",
+ "add_notice" : "お知らせ配信",
+ "server_settings" : "サーバー設定",
+ "logout" : "ログアウト",
+ "notice" : "お知らせ",
+ "editor" : "編集者",
+ "server_about" : "サーバー情報",
+ "server" : "Server",
+ "software" : "software",
+ "terms" : "利用規約",
+ "privacy_policy" : "プライバシーポリシー",
+ "detail" : "詳細",
+ "learn_more" : "もっと詳しく!",
+ "release_note" : "リリースノート",
+ "about" : "概要",
+ "user" : "ユーザー",
+ "user_management" : "ユーザー管理",
+ "invitation" : "招待",
+ "invitation_code" : "招待コード",
+ "role" : "ロール",
+ "ads" : "広告",
+ "moderation" : "モデレーション",
+ "customize" : "カスタマイズ",
+ "ueuse" : "ユーズ",
+ "media" : "メディア",
+ "favorite" : "いいね",
+ "ima_dou_siteru" : "いまどうしてる?",
+ "ueuse_search" : "ユーズ検索",
+ "all_emoji" : "絵文字一覧",
+ "ueuse_count" : "ユーズ数",
+ "follow_count" : "フォロー数",
+ "follower_count" : "フォロワー数",
+ "follow" : "フォロー",
+ "follower" : "フォロワー"
+}
\ No newline at end of file
diff --git a/login.php b/login.php
index 8dfc00d..676024e 100644
--- a/login.php
+++ b/login.php
@@ -6,6 +6,8 @@ $serversettings = parse_ini_file($serversettings_file, true);
require('db.php');
//hCaptcha--------------------------------------------
require('settings_admin/hCaptcha_settings/hCaptcha_settings.php');
+//Cloudflare_Turnstile--------------------------------------------
+require('settings_admin/CloudflareTurnstile_settings/CloudflareTurnstile_settings.php');
//----------------------------------------------------
@@ -96,14 +98,14 @@ if( !empty($_POST['btn_submit']) ) {
$userid = htmlentities($_POST['userid']);
$password = htmlentities($_POST['password']);
- if(!empty(CAPTCHA && CAPTCHA == "true")){
+ if(!empty(H_CAPTCHA_ONOFF && H_CAPTCHA_ONOFF == "true")){
if(isset($_POST['h-captcha-response'])){
$hcaptcha_token = htmlentities($_POST['h-captcha-response']);
if($hcaptcha_token){
$captcha_data = [
- 'secret' => htmlentities(SEAC_KEY),
+ 'secret' => htmlentities(H_CAPTCHA_SEAC_KEY),
'response' => $hcaptcha_token,
- 'sitekey' => htmlentities(SITE_KEY)
+ 'sitekey' => htmlentities(H_CAPTCHA_SITE_KEY)
];
$options = [
'http' => [
@@ -114,13 +116,39 @@ if( !empty($_POST['btn_submit']) ) {
];
$hCaptcha_result = json_decode(file_get_contents('https://hcaptcha.com/siteverify', false, stream_context_create($options)),true);
if(!($hCaptcha_result["success"] == true)){
- $error_message[] = "あなたが人間である確認ができませんでした。(ERROR)";
+ $error_message[] = "hCaptchaであなたが人間である確認ができませんでした。(ERROR)";
}
}else{
- $error_message[] = "あなたが人間である確認ができませんでした。(ERROR)";
+ $error_message[] = "hCaptchaであなたが人間である確認ができませんでした。(ERROR)";
}
}else{
- $error_message[] = "あなたが人間である確認ができませんでした。(ERROR)";
+ $error_message[] = "hCaptchaであなたが人間である確認ができませんでした。(ERROR)";
+ }
+ }
+ if(!empty(CF_TURNSTILE_ONOFF && CF_TURNSTILE_ONOFF == "true")){
+ if(isset($_POST['cf-turnstile-response'])){
+ $CF_Turnstile_token = htmlentities($_POST['cf-turnstile-response']);
+ if($CF_Turnstile_token){
+ $CF_Turnstile_data = [
+ 'secret' => htmlentities(CF_TURNSTILE_SEAC_KEY),
+ 'response' => $CF_Turnstile_token
+ ];
+ $CF_Turnstile_options = [
+ 'http' => [
+ 'method'=> 'POST',
+ 'header'=> 'Content-Type: application/x-www-form-urlencoded',
+ 'content' => http_build_query($CF_Turnstile_data, '', '&')
+ ]
+ ];
+ $CF_Turnstile_result = json_decode(file_get_contents('https://challenges.cloudflare.com/turnstile/v0/siteverify', false, stream_context_create($CF_Turnstile_options)),true);
+ if(!($CF_Turnstile_result["success"] == true)){
+ $error_message[] = "CloudflareTurnstileであなたが人間である確認ができませんでした。(ERROR)";
+ }
+ }else{
+ $error_message[] = "CloudflareTurnstileであなたが人間である確認ができませんでした。(ERROR)";
+ }
+ }else{
+ $error_message[] = "CloudflareTurnstileであなたが人間である確認ができませんでした。(ERROR)";
}
}
@@ -219,10 +247,14 @@ $pdo = null;
+
-
+
+
+
+
@@ -265,10 +297,24 @@ $pdo = null;
-
+
+
+
人間だと思いますが一応お伺いします...
人間ですか?
人間の場合はチェックボックスにチェックしてください!
-
+
+
+
+
+
+
@@ -292,13 +338,13 @@ function checkForm(inputElement) {
}
inputElement.value = str;
}
-
-
-window.onload = function(){
-var ele = document.getElementsByTagName("body")[0];
-var n = Math.floor(Math.random() * 3); // 3枚の画像がある場合
-ele.style.backgroundImage = "url(img/titleimg/"+n+".png)";
-}
+$("#passview").click(function () {
+ if ($("#passview").prop("checked") == true) {
+ $('#password').get(0).type = 'text';
+ } else {
+ $('#password').get(0).type = 'password';
+ }
+});
diff --git a/logout/index.php b/logout/index.php
index ad8a584..df2c080 100644
--- a/logout/index.php
+++ b/logout/index.php
@@ -34,6 +34,7 @@ $_SESSION = null;
+
diff --git a/new.php b/new.php
index c27e185..f115608 100644
--- a/new.php
+++ b/new.php
@@ -20,6 +20,8 @@ require('db.php');
require('function/function.php');
//hCaptcha--------------------------------------------
require('settings_admin/hCaptcha_settings/hCaptcha_settings.php');
+//Cloudflare_Turnstile--------------------------------------------
+require('settings_admin/CloudflareTurnstile_settings/CloudflareTurnstile_settings.php');
//----------------------------------------------------
$serversettings_file = "server/serversettings.ini";
@@ -117,14 +119,14 @@ if( !empty($_POST['btn_submit']) ) {
$invitationcode = $_POST['invitationcode'];
}
- if(!empty(CAPTCHA && CAPTCHA == "true")){
+ if(!empty(H_CAPTCHA_ONOFF && H_CAPTCHA_ONOFF == "true")){
if(isset($_POST['h-captcha-response'])){
$hcaptcha_token = htmlentities($_POST['h-captcha-response']);
if($hcaptcha_token){
$captcha_data = [
- 'secret' => htmlentities(SEAC_KEY),
+ 'secret' => htmlentities(H_CAPTCHA_SEAC_KEY),
'response' => $hcaptcha_token,
- 'sitekey' => htmlentities(SITE_KEY)
+ 'sitekey' => htmlentities(H_CAPTCHA_SITE_KEY)
];
$options = [
'http' => [
@@ -135,13 +137,39 @@ if( !empty($_POST['btn_submit']) ) {
];
$hCaptcha_result = json_decode(file_get_contents('https://hcaptcha.com/siteverify', false, stream_context_create($options)),true);
if(!($hCaptcha_result["success"] == true)){
- $error_message[] = "あなたが人間である確認ができませんでした。(ERROR)";
+ $error_message[] = "hCaptchaであなたが人間である確認ができませんでした。(ERROR)";
}
}else{
- $error_message[] = "あなたが人間である確認ができませんでした。(ERROR)";
+ $error_message[] = "hCaptchaであなたが人間である確認ができませんでした。(ERROR)";
}
}else{
- $error_message[] = "あなたが人間である確認ができませんでした。(ERROR)";
+ $error_message[] = "hCaptchaであなたが人間である確認ができませんでした。(ERROR)";
+ }
+ }
+ if(!empty(CF_TURNSTILE_ONOFF && CF_TURNSTILE_ONOFF == "true")){
+ if(isset($_POST['cf-turnstile-response'])){
+ $CF_Turnstile_token = htmlentities($_POST['cf-turnstile-response']);
+ if($CF_Turnstile_token){
+ $CF_Turnstile_data = [
+ 'secret' => htmlentities(CF_TURNSTILE_SEAC_KEY),
+ 'response' => $CF_Turnstile_token
+ ];
+ $CF_Turnstile_options = [
+ 'http' => [
+ 'method'=> 'POST',
+ 'header'=> 'Content-Type: application/x-www-form-urlencoded',
+ 'content' => http_build_query($CF_Turnstile_data, '', '&')
+ ]
+ ];
+ $CF_Turnstile_result = json_decode(file_get_contents('https://challenges.cloudflare.com/turnstile/v0/siteverify', false, stream_context_create($CF_Turnstile_options)),true);
+ if(!($CF_Turnstile_result["success"] == true)){
+ $error_message[] = "CloudflareTurnstileであなたが人間である確認ができませんでした。(ERROR)";
+ }
+ }else{
+ $error_message[] = "CloudflareTurnstileであなたが人間である確認ができませんでした。(ERROR)";
+ }
+ }else{
+ $error_message[] = "CloudflareTurnstileであなたが人間である確認ができませんでした。(ERROR)";
}
}
@@ -400,8 +428,8 @@ if( !empty($_POST['btn_submit']) ) {
}
// 文字数を確認
- if( 100 < mb_strlen($password, 'UTF-8') ) {
- $error_message[] = 'パスワードは100文字以内で入力してください。(PASSWORD_OVER_MAX_COUNT)';
+ if( 256 < mb_strlen($password, 'UTF-8') ) {
+ $error_message[] = 'パスワードは256文字以内で入力してください。(PASSWORD_OVER_MAX_COUNT)';
}
}
@@ -506,10 +534,14 @@ $pdo = null;
+
-
+
+
+
+
@@ -600,10 +632,15 @@ $pdo = null;
登録を押すと利用規約とプライバシーポリシーに同意したこととなります。
未確認の場合は上のボタンよりお読みください。
-
+
あなたは人間ですか?
もし人間であれば下のチェックボックスにチェックしてください!
-
+
+
+
+
+
diff --git a/nextpage/emojiview.php b/nextpage/emojiview.php
new file mode 100644
index 0000000..c1f2d0a
--- /dev/null
+++ b/nextpage/emojiview.php
@@ -0,0 +1,113 @@
+ PDO::ERRMODE_EXCEPTION,
+ PDO::MYSQL_ATTR_MULTI_STATEMENTS => false
+ );
+ $pdo = new PDO('mysql:charset=utf8mb4;dbname=' . DB_NAME . ';host=' . DB_HOST, DB_USER, DB_PASS, $option);
+} catch (PDOException $e) {
+ // 接続エラーのときエラー内容を取得する
+ $error_message[] = $e->getMessage();
+}
+
+if (isset($_GET['userid']) && isset($_GET['account_id']) && isset($_GET['search_query']) && isset($_GET['view_mode'])) {
+ $userid = htmlentities($_GET['userid'], ENT_QUOTES, 'UTF-8', false);
+ $loginid = htmlentities($_GET['account_id'], ENT_QUOTES, 'UTF-8', false);
+ $search_word = str_replace(":","",htmlentities($_GET['search_query'], ENT_QUOTES, 'UTF-8', false));
+ $viewmode = htmlentities($_GET['view_mode'], ENT_QUOTES, 'UTF-8', false);
+
+ $itemsPerPage = 50;
+ $pageNumber = htmlentities(isset($_GET['page'])) ? htmlentities(intval($_GET['page'])) : 1;
+ $offset = ($pageNumber - 1) * $itemsPerPage;
+
+ // データベース接続の設定
+ $dbh = new PDO('mysql:charset=utf8mb4;dbname='.DB_NAME.';host='.DB_HOST, DB_USER, DB_PASS, array(
+ PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
+ PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC,
+ PDO::MYSQL_ATTR_USE_BUFFERED_QUERY => true,
+ ));
+
+ $query = $dbh->prepare('SELECT * FROM account WHERE userid = :userid limit 1');
+
+ $query->execute(array(':userid' => $userid));
+
+ $result2 = $query->fetch();
+
+ if(!(empty($result2["loginid"]))){
+ if($result2["loginid"] === $loginid){
+ $custom_emoji = array();
+ if (!(empty($pdo))) {
+
+ if(!(empty($search_word))){
+ $custom_emoji_Query = $pdo->prepare("SELECT emojifile,emojiname,emojiinfo,emojidate FROM emoji WHERE emojiname LIKE :keyword OR emojiinfo LIKE :keyword ORDER BY emojidate DESC");
+ $custom_emoji_Query->bindValue(':keyword', '%' . $search_word . '%', PDO::PARAM_STR);
+ $custom_emoji_Query->execute();
+ }else{
+ $custom_emoji_Query = $pdo->prepare("SELECT emojifile,emojiname,emojiinfo,emojidate FROM emoji ORDER BY emojidate DESC LIMIT :offset, :itemsPerPage");
+ $custom_emoji_Query->bindValue(':offset', $offset, PDO::PARAM_INT);
+ $custom_emoji_Query->bindValue(':itemsPerPage', $itemsPerPage, PDO::PARAM_INT);
+ $custom_emoji_Query->execute();
+ }
+
+ $custom_array = $custom_emoji_Query->fetchAll();
+
+ $custom_emoji = array();
+ foreach ($custom_array as $row) {
+ $custom_emoji[] = $row;
+ }
+
+ if((!(empty($custom_emoji)))&&(!(empty($viewmode)))){
+ if($viewmode == "page"){
+ foreach ($custom_emoji as $value) {
+ echo '';
+ echo '
';
+ echo '

';
+ echo '
';
+ echo '
:'.htmlentities($value["emojiname"], ENT_QUOTES, 'UTF-8', false).':
';
+ echo '
'.htmlentities($value["emojiinfo"], ENT_QUOTES, 'UTF-8', false).'
';
+ echo '
';
+ echo '
';
+ echo '
';
+ }
+ }elseif($viewmode == "picker"){
+ foreach ($custom_emoji as $value) {
+ echo '';
+ echo '

';
+ echo '
';
+ }
+ }else{
+ echo '';
+ }
+ }else{
+ echo '';
+ }
+
+
+ }else{
+ echo '';
+ }
+
+ }else{
+ echo '';
+ }
+
+ $pdo = null;
+
+ }else{
+ echo '';
+ }
+}else{
+ echo '';
+}
\ No newline at end of file
diff --git a/nextpage/notification.php b/nextpage/notification.php
index 0f1d2c5..948a664 100644
--- a/nextpage/notification.php
+++ b/nextpage/notification.php
@@ -55,8 +55,10 @@ if (isset($_GET['userid']) && isset($_GET['account_id'])) {
PDO::MYSQL_ATTR_USE_BUFFERED_QUERY => true,
));
- $messageQuery = $dbh->prepare("SELECT fromuserid,title,msg,url,datetime,userchk FROM notification WHERE touserid = :userid ORDER BY datetime DESC LIMIT $offset, $itemsPerPage");
- $messageQuery->bindValue(':userid', $userid);
+ $messageQuery = $dbh->prepare("SELECT fromuserid,title,msg,url,datetime,userchk FROM notification WHERE touserid = :userid ORDER BY datetime DESC LIMIT :offset, :itemsPerPage");
+ $messageQuery->bindValue(':userid', $userid, PDO::PARAM_STR);
+ $messageQuery->bindValue(':offset', $offset, PDO::PARAM_INT);
+ $messageQuery->bindValue(':itemsPerPage', $itemsPerPage, PDO::PARAM_INT);
$messageQuery->execute();
$message_array = $messageQuery->fetchAll();
@@ -73,7 +75,7 @@ if (isset($_GET['userid']) && isset($_GET['account_id'])) {
if (!empty($message_array)) {
foreach ($message_array as $value) {
- $value["servericon"] = htmlspecialchars($serversettings["serverinfo"]["server_icon"], ENT_QUOTES, 'UTF-8', false);
+ $value["servericon"] = htmlentities($serversettings["serverinfo"]["server_icon"], ENT_QUOTES, 'UTF-8', false);
if(!(empty($value['fromuserid']))){
if(!($value['fromuserid'] == "uwuzu-fromsys")){
$userQuery = $dbh->prepare("SELECT username,iconname FROM account WHERE userid = :userid");
@@ -94,6 +96,8 @@ if (isset($_GET['userid']) && isset($_GET['account_id'])) {
$pdo = null;
+ }else{
+ echo '';
}
}else{
echo '';
diff --git a/nextpage/notificationview.php b/nextpage/notificationview.php
index 0de2ffe..8086df1 100644
--- a/nextpage/notificationview.php
+++ b/nextpage/notificationview.php
@@ -1,123 +1,7 @@
$1', $markdownText);//ぶるぶる
-
- $markdownText = preg_replace('/(^|[^`])`([^`\n]+)`($|[^`])/m', '$1$2$3', $markdownText);//Inline Code
-
- $markdownText = preg_replace('/\*\*\*(.*?)\*\*\*/', '$1', $markdownText);//太字&斜体の全部のせセット
- $markdownText = preg_replace('/\_\_\_(.*?)\_\_\_/', '$1', $markdownText);//太字&斜体の全部のせセット
-
- $markdownText = preg_replace('/\*\*(.*?)\*\*/', '$1', $markdownText);//太字
- $markdownText = preg_replace('/\_\_(.*?)\_\_/', '$1', $markdownText);//太字
-
- $markdownText = preg_replace('/\*(.*?)\*/', '$1', $markdownText);//斜体
- $markdownText = preg_replace('/\_(.*?)\_/', '$1', $markdownText);//斜体
-
- $markdownText = preg_replace('/\~\~(.*?)\~\~/m', '$1', $markdownText);//打ち消し線
-
- $markdownText = preg_replace('/>>> (.*)/m', '$1', $markdownText);//>>> 引用
-
- $markdownText = preg_replace('/\|\|(.*)\|\|/m', '$1', $markdownText);//黒塗り
-
- // タイトル(#、##、###)をHTMLのhタグに変換
- $markdownText = preg_replace('/^# (.+)/m', '$1
', $markdownText);
- $markdownText = preg_replace('/^## (.+)/m', '$1
', $markdownText);
- $markdownText = preg_replace('/^### (.+)/m', '$1
', $markdownText);
-
- // 箇条書き(-)をHTMLのul/liタグに変換
- $markdownText = preg_replace('/^- (.+)/m', '・ $1
', $markdownText);
-
- // 空行の前に何もない行をHTMLのpタグに変換
- $markdownText = preg_replace('/(^\s*)(?!\s)(.*)/m', '$1$2
', $markdownText);
-
- return $markdownText;
-}
-//Profile
-function replaceProfileEmojiImages($postText) {
- $postText = str_replace(''', '\'', $postText);
- // プロフィール名で絵文字名(:emoji:)を検出して画像に置き換える
- $emojiPattern = '/:(\w+):/';
- $postTextWithImages = preg_replace_callback($emojiPattern, function($matches) {
- $emojiName = $matches[1];
- //絵文字path取得
- $dbh = new PDO('mysql:charset=utf8mb4;dbname='.DB_NAME.';host='.DB_HOST, DB_USER, DB_PASS, array(
- PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
- PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC,
- PDO::MYSQL_ATTR_USE_BUFFERED_QUERY => true,
- ));
- $emoji_Query = $dbh->prepare("SELECT emojifile, emojiname FROM emoji WHERE emojiname = :emojiname");
- $emoji_Query->bindValue(':emojiname', $emojiName);
- $emoji_Query->execute();
- $emoji_row = $emoji_Query->fetch();
- if(empty($emoji_row["emojifile"])){
- $emoji_path = "img/sysimage/errorimage/emoji_404.png";
- }else{
- $emoji_path = $emoji_row["emojifile"];
- }
- return "
";
- }, $postText);
- return $postTextWithImages;
-}
-function replaceEmojisWithImages($postText) {
- $postText = str_replace(''', '\'', $postText);
- // ユーズ内で絵文字名(:emoji:)を検出して画像に置き換える
- $emojiPattern = '/:(\w+):/';
- $postTextWithImages = preg_replace_callback($emojiPattern, function($matches) {
- $emojiName = $matches[1];
- //絵文字path取得
- $dbh = new PDO('mysql:charset=utf8mb4;dbname='.DB_NAME.';host='.DB_HOST, DB_USER, DB_PASS, array(
- PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
- PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC,
- PDO::MYSQL_ATTR_USE_BUFFERED_QUERY => true,
- ));
- $emoji_Query = $dbh->prepare("SELECT emojifile, emojiname FROM emoji WHERE emojiname = :emojiname");
- $emoji_Query->bindValue(':emojiname', $emojiName);
- $emoji_Query->execute();
- $emoji_row = $emoji_Query->fetch();
- if(empty($emoji_row["emojifile"])){
- $emoji_path = "img/sysimage/errorimage/emoji_404.png";
- }else{
- $emoji_path = $emoji_row["emojifile"];
- }
- return "
";
- }, $postText);
-
- // @username を検出してリンクに置き換える
- $usernamePattern = '/@(\w+)/';
- $postTextWithImagesAndUsernames = preg_replace_callback($usernamePattern, function($matches) {
- $username = $matches[1];
-
- $dbh = new PDO('mysql:charset=utf8mb4;dbname='.DB_NAME.';host='.DB_HOST, DB_USER, DB_PASS, array(
- PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
- PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC,
- PDO::MYSQL_ATTR_USE_BUFFERED_QUERY => true,
- ));
-
- $mentionsuserQuery = $dbh->prepare("SELECT username, userid FROM account WHERE userid = :userid");
- $mentionsuserQuery->bindValue(':userid', $username);
- $mentionsuserQuery->execute();
- $mentionsuserData = $mentionsuserQuery->fetch();
-
- if(empty($mentionsuserData)){
- return "@$username";
- }else{
- return "@".replaceProfileEmojiImages(htmlspecialchars($mentionsuserData["username"], ENT_QUOTES, 'UTF-8', false))."";
- }
- }, $postTextWithImages);
-
- $hashtagsPattern = '/#([\p{Han}\p{Hiragana}\p{Katakana}A-Za-z0-9ー_]+)/u';
- $postTextWithHashtags = preg_replace_callback($hashtagsPattern, function($matches) {
- $hashtags = $matches[1];
- return "" . '#' . htmlspecialchars($hashtags, ENT_QUOTES, 'UTF-8', false) . "";
- }, $postTextWithImagesAndUsernames);
-
- return $postTextWithHashtags;
-}
+//関数呼び出し
+//- 文字装飾・URL変換など
+require('../function/function.php');
class MessageDisplay {
private $value;
@@ -135,11 +19,11 @@ class MessageDisplay {
echo ' ';
echo '
';
- $day = date("Ymd", strtotime(htmlspecialchars($this->value['datetime'], ENT_QUOTES, 'UTF-8', false)));
+ $day = date("Ymd", strtotime(htmlentities($this->value['datetime'], ENT_QUOTES, 'UTF-8', false)));
if ($day == date("Ymd")) {
- echo date("今日 H:i", strtotime(htmlspecialchars($this->value['datetime'], ENT_QUOTES, 'UTF-8', false)));
+ echo date("今日 H:i", strtotime(htmlentities($this->value['datetime'], ENT_QUOTES, 'UTF-8', false)));
} else {
- echo date("Y年m月d日 H:i", strtotime(htmlspecialchars($this->value['datetime'], ENT_QUOTES, 'UTF-8', false)));
+ echo date("Y年m月d日 H:i", strtotime(htmlentities($this->value['datetime'], ENT_QUOTES, 'UTF-8', false)));
}
echo '
';
@@ -151,24 +35,24 @@ class MessageDisplay {
echo '
';
if(($this->value['fromuserid'] == "uwuzu-fromsys")){
if(!(empty($this->value["servericon"]))){
- echo '

';
+ echo '

';
}else{
echo '

';
}
}else{
- echo '
 . ')
';
+ echo '
 . ')
';
}
echo '
';
if(($this->value['fromuserid'] == "uwuzu-fromsys")){
echo '
';
}else{
- echo '
';
+ echo '
';
}
echo '
';
}
- echo ' ' . replaceEmojisWithImages(htmlspecialchars($this->value['title'], ENT_QUOTES, 'UTF-8', false)) . '
';
- echo ' ' . processMarkdownAndWrapEmptyLines(replaceEmojisWithImages(nl2br(htmlspecialchars($this->value['msg'], ENT_QUOTES, 'UTF-8', false)))) . '
';
- echo ' 詳細をみる';
+ echo ' ' . replaceEmojisWithImages(htmlentities($this->value['title'], ENT_QUOTES, 'UTF-8', false)) . '
';
+ echo ' ' . processMarkdownAndWrapEmptyLines(replaceEmojisWithImages(nl2br(htmlentities($this->value['msg'], ENT_QUOTES, 'UTF-8', false)))) . '
';
+ echo ' 詳細をみる';
echo '';
}
diff --git a/nextpage/user_view.php b/nextpage/user_view.php
index 8b0878c..74d267d 100644
--- a/nextpage/user_view.php
+++ b/nextpage/user_view.php
@@ -17,16 +17,16 @@ class UserdataDisplay {
echo '';
echo '
';
- echo '
 . ')
';
+ echo '
 . ')
';
echo '
';
echo '
';
echo '
';
echo '
';
- echo '
' .replaceEmojisWithImages(replaceURLsWithLinks(nl2br(htmlspecialchars($this->value['profile'], ENT_QUOTES, 'UTF-8', false)))) . '
';
+ echo '
' .replaceEmojisWithImages(replaceURLsWithLinks(nl2br(htmlentities($this->value['profile'], ENT_QUOTES, 'UTF-8', false)))) . '
';
echo '
';
echo '
';
diff --git a/nextpage/view.php b/nextpage/view.php
index a050df5..314d4f9 100644
--- a/nextpage/view.php
+++ b/nextpage/view.php
@@ -1,226 +1,8 @@
$1', $markdownText);//ぶるぶる
-
- $markdownText = preg_replace('/(^|[^`])`([^`\n]+)`($|[^`])/m', '$1
$2$3', $markdownText);//Inline Code
-
- /*$markdownText = preg_replace_callback('/^\[\[time (\d+)\]\]/m', function($matches) {
- $timestamp = $matches[1];
- return '
' . date("Y/m/d H:i:s", $timestamp) . '';
- }, $markdownText);*/
-
- $markdownText = preg_replace('/\*\*\*(.*?)\*\*\*/', '
$1', $markdownText);//太字&斜体の全部のせセット
- $markdownText = preg_replace('/\_\_\_(.*?)\_\_\_/', '
$1', $markdownText);//太字&斜体の全部のせセット
-
- $markdownText = preg_replace('/\*\*(.*?)\*\*/', '
$1', $markdownText);//太字
- $markdownText = preg_replace('/\_\_(.*?)\_\_/', '
$1', $markdownText);//太字
-
- $markdownText = preg_replace('/\*(.*?)\*/', '
$1', $markdownText);//斜体
- $markdownText = preg_replace('/\_(.*?)\_/', '
$1', $markdownText);//斜体
-
- $markdownText = preg_replace('/\~\~(.*?)\~\~/m', '
$1', $markdownText);//打ち消し線
-
- $markdownText = preg_replace('/>>> (.*)/m', '
$1', $markdownText);//>>> 引用
-
- $markdownText = preg_replace('/\|\|(.*)\|\|/m', '
$1', $markdownText);//黒塗り
-
- // タイトル(#、##、###)をHTMLのhタグに変換
- $markdownText = preg_replace('/^# (.+)/m', '
$1
', $markdownText);
- $markdownText = preg_replace('/^## (.+)/m', '
$1
', $markdownText);
- $markdownText = preg_replace('/^### (.+)/m', '
$1
', $markdownText);
-
- // 箇条書き(-)をHTMLのul/liタグに変換
- $markdownText = preg_replace('/^- (.+)/m', '
・ $1
', $markdownText);
-
- // 空行の前に何もない行をHTMLのpタグに変換
- $markdownText = preg_replace('/(^\s*)(?!\s)(.*)/m', '$1
$2
', $markdownText);
-
- return $markdownText;
-}
-//Profile
-function replaceProfileEmojiImages($postText) {
- $postText = str_replace(''', '\'', $postText);
- // プロフィール名で絵文字名(:emoji:)を検出して画像に置き換える
- $emojiPattern = '/:(\w+):/';
- $postTextWithImages = preg_replace_callback($emojiPattern, function($matches) {
- $emojiName = $matches[1];
- //絵文字path取得
- $dbh = new PDO('mysql:charset=utf8mb4;dbname='.DB_NAME.';host='.DB_HOST, DB_USER, DB_PASS, array(
- PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
- PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC,
- PDO::MYSQL_ATTR_USE_BUFFERED_QUERY => true,
- ));
- $emoji_Query = $dbh->prepare("SELECT emojifile, emojiname FROM emoji WHERE emojiname = :emojiname");
- $emoji_Query->bindValue(':emojiname', $emojiName);
- $emoji_Query->execute();
- $emoji_row = $emoji_Query->fetch();
- if(empty($emoji_row["emojifile"])){
- $emoji_path = "img/sysimage/errorimage/emoji_404.png";
- }else{
- $emoji_path = $emoji_row["emojifile"];
- }
- return "

";
- }, $postText);
- return $postTextWithImages;
-}
-// ユーズ内の絵文字やhashtagを画像に置き換える
-function replaceEmojisWithImages($postText) {
- $postText = str_replace(''', '\'', $postText);
- // ユーズ内で絵文字名(:emoji:)を検出して画像に置き換える
- $emojiPattern = '/:(\w+):/';
- $postTextWithImages = preg_replace_callback($emojiPattern, function($matches) {
- $emojiName = $matches[1];
- //絵文字path取得
- $dbh = new PDO('mysql:charset=utf8mb4;dbname='.DB_NAME.';host='.DB_HOST, DB_USER, DB_PASS, array(
- PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
- PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC,
- PDO::MYSQL_ATTR_USE_BUFFERED_QUERY => true,
- ));
- $emoji_Query = $dbh->prepare("SELECT emojifile, emojiname FROM emoji WHERE emojiname = :emojiname");
- $emoji_Query->bindValue(':emojiname', $emojiName);
- $emoji_Query->execute();
- $emoji_row = $emoji_Query->fetch();
- if(empty($emoji_row["emojifile"])){
- $emoji_path = "img/sysimage/errorimage/emoji_404.png";
- }else{
- $emoji_path = $emoji_row["emojifile"];
- }
- return "

";
- }, $postText);
-
- // @username を検出してリンクに置き換える
- $usernamePattern = '/@(\w+)/';
- $postTextWithImagesAndUsernames = preg_replace_callback($usernamePattern, function($matches) {
- $username = $matches[1];
-
- $dbh = new PDO('mysql:charset=utf8mb4;dbname='.DB_NAME.';host='.DB_HOST, DB_USER, DB_PASS, array(
- PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
- PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC,
- PDO::MYSQL_ATTR_USE_BUFFERED_QUERY => true,
- ));
-
- $mentionsuserQuery = $dbh->prepare("SELECT username, userid FROM account WHERE userid = :userid");
- $mentionsuserQuery->bindValue(':userid', $username);
- $mentionsuserQuery->execute();
- $mentionsuserData = $mentionsuserQuery->fetch();
-
- if(empty($mentionsuserData)){
- return "@$username";
- }else{
- return "
@".replaceProfileEmojiImages(htmlspecialchars($mentionsuserData["username"], ENT_QUOTES, 'UTF-8', false))."";
- }
- }, $postTextWithImages);
-
- $hashtagsPattern = '/#([\p{Han}\p{Hiragana}\p{Katakana}A-Za-z0-9ー_]+)/u';
- $postTextWithHashtags = preg_replace_callback($hashtagsPattern, function($matches) {
- $hashtags = $matches[1];
- return "
" . '#' . $hashtags . "";
- }, $postTextWithImagesAndUsernames);
-
- return $postTextWithHashtags;
-}
-function replaceURLsWithLinks($postText) {
- // URLを正規表現を使って検出
- $pattern = '/(https:\/\/[^\s<>\[\]\'"]+)/'; // 改良された正規表現
- preg_match_all($pattern, $postText, $matches);
-
- // 検出したURLごとに処理を行う
- foreach ($matches[0] as $url) {
- // ドメイン部分を抽出
- $parsedUrl = parse_url($url);
- if (!isset($parsedUrl['path'])) {
- $parsedUrl['path'] = '';
- }
- if (!isset($parsedUrl['query'])) {
- $parsedUrl['query'] = '';
- }
-
- $nochk_domain = $parsedUrl['host'].$parsedUrl['path'].$parsedUrl['query'];
-
- if(strlen($nochk_domain) > 47){
- $domain = mb_substr($nochk_domain, 0, 48, "UTF-8")."...";
- }else{
- $domain = $nochk_domain;
- }
-
- // 不要な文字を削除してaタグを生成
- $urlWithoutSpaces = preg_replace('/\s+/', '', $url);
- $link = "
$domain";
-
- // URLをドメインのみを表示するaタグで置き換え
- $postText = preg_replace('/' . preg_quote($url, '/') . '/', $link, $postText);
- }
-
- return $postText;
-}
-function YouTube_and_nicovideo_Links($postText) {
- // URLを正規表現を使って検出
- $pattern = '/(https:\/\/[^\s<>\[\]\'"]+)/'; // 改良された正規表現
- preg_match_all($pattern, $postText, $matches);
-
- if(empty($url)){
- $postText = "";
- }
-
- // 検出したURLごとに処理を行う
- foreach ($matches[0] as $url) {
- // ドメイン部分を抽出
- $parsedUrl = parse_url($url);
- if($parsedUrl['host'] == "youtube.com" || $parsedUrl['host'] == "youtu.be" || $parsedUrl['host'] == "www.youtube.com" || $parsedUrl['host'] == "m.youtube.com"){
-
- if (isset($parsedUrl['query'])) {
- if(false !== strpos($parsedUrl['query'], 'v=')) {
- $video_id = str_replace('v=', '', htmlspecialchars($parsedUrl['query'], ENT_QUOTES, 'UTF-8', false));
- $iframe = true;
- }else{
- $video_id = str_replace('/', '', htmlspecialchars($parsedUrl['path'], ENT_QUOTES, 'UTF-8', false));
- $iframe = true;
- }
- }elseif(isset($parsedUrl['path'])){
- $video_id = str_replace('/', '', htmlspecialchars($parsedUrl['path'], ENT_QUOTES, 'UTF-8', false));
- $iframe = true;
- }else{
- $video_id = "";
- $iframe = false;
- }
- // 不要な文字を削除してaタグを生成
- if($iframe == true){
- $link = '
';
- }else{
- $link = "";
- }
- // URLをドメインのみを表示するaタグで置き換え
- $postText = $link;
- }elseif($parsedUrl['host'] == "nicovideo.jp" || $parsedUrl['host'] == "www.nicovideo.jp"){
-
- if(isset($parsedUrl['path'])){
- $video_id = str_replace('/watch/', '', htmlspecialchars($parsedUrl['path'], ENT_QUOTES, 'UTF-8', false));
- $iframe = true;
- }else{
- $video_id = "";
- $iframe = false;
- }
- // 不要な文字を削除してaタグを生成
- if($iframe == true){
- $link = '
@@ -375,6 +375,7 @@ if (!empty($pdo)) {
+
diff --git a/settings_admin/userinfo.php b/settings_admin/userinfo.php
index 329e72f..4fc41cc 100644
--- a/settings_admin/userinfo.php
+++ b/settings_admin/userinfo.php
@@ -201,7 +201,7 @@ if (!empty($pdo)) {
$roleDataArray = array();
foreach ($roles as $roleId) {
- $rerole = $dbh->prepare("SELECT rolename, roleauth, rolecolor FROM role WHERE roleidname = :role");
+ $rerole = $dbh->prepare("SELECT rolename, roleauth, rolecolor, roleeffect FROM role WHERE roleidname = :role");
$rerole->bindValue(':role', $roleId);
$rerole->execute();
$roleDataArray[$roleId] = $rerole->fetch();
@@ -264,8 +264,8 @@ if( !empty($_POST['send_ice_submit']) ) {
if(!empty(MAIL_CHKS && MAIL_CHKS == "true")){
if( !empty($userdata["mailadds"]) ){
if(filter_var($userdata["mailadds"], FILTER_VALIDATE_EMAIL)){
- $mail_title = "お使いの".htmlspecialchars($serversettings["serverinfo"]["server_name"], ENT_QUOTES, 'UTF-8')."アカウントは凍結されました";
- $mail_text = "".$userdata["username"]."(".$userdata["userid"].")さん いつもuwuzuをご利用いただきありがとうございます。 ご利用のアカウント(".$userdata["userid"].")が".htmlspecialchars($serversettings["serverinfo"]["server_name"], ENT_QUOTES, 'UTF-8')."管理者により凍結されたためお知らせいたします。 サービス管理者からのメッセージは以下のものです。 ". $notice_msg ." 異議申し立てする場合は[".htmlspecialchars($serversettings["serverinfo"]["server_admin_mailadds"], ENT_QUOTES, 'UTF-8')."]まで異議申し立てをする旨を記載し送信をしてください。";
+ $mail_title = "お使いの".htmlentities($serversettings["serverinfo"]["server_name"], ENT_QUOTES, 'UTF-8')."アカウントは凍結されました";
+ $mail_text = "".$userdata["username"]."(".$userdata["userid"].")さん いつもuwuzuをご利用いただきありがとうございます。 ご利用のアカウント(".$userdata["userid"].")が".htmlentities($serversettings["serverinfo"]["server_name"], ENT_QUOTES, 'UTF-8')."管理者により凍結されたためお知らせいたします。 サービス管理者からのメッセージは以下のものです。 ". $notice_msg ." 異議申し立てする場合は[".htmlentities($serversettings["serverinfo"]["server_admin_mailadds"], ENT_QUOTES, 'UTF-8')."]まで異議申し立てをする旨を記載し送信をしてください。";
send_html_mail($userdata["mailadds"],$mail_title,$mail_text,"../");
}
@@ -352,7 +352,7 @@ if( !empty($_POST['send_water_submit']) ) {
if(!empty(MAIL_CHKS && MAIL_CHKS == "true")){
if( !empty($userdata["mailadds"]) ){
if(filter_var($userdata["mailadds"], FILTER_VALIDATE_EMAIL)){
- $mail_title = "お使いの".htmlspecialchars($serversettings["serverinfo"]["server_name"], ENT_QUOTES, 'UTF-8')."アカウントは解凍されました!";
+ $mail_title = "お使いの".htmlentities($serversettings["serverinfo"]["server_name"], ENT_QUOTES, 'UTF-8')."アカウントは解凍されました!";
$mail_text = "".$userdata["username"]."(".$userdata["userid"].")さん いつもuwuzuをご利用いただきありがとうございます。 ご利用のアカウント(".$userdata["userid"].")が解凍されたためお知らせいたします。 今後、ご利用のuwuzuアカウントは今まで通りご利用いただけます。 また、APIを使用している方はAPIのトークンがリセットされているため再度トークンを発行してご利用ください。";
send_html_mail($userdata["mailadds"],$mail_title,$mail_text,"../");
@@ -535,8 +535,8 @@ if( !empty($_POST['send_ban_submit']) ) {
if(!empty(MAIL_CHKS && MAIL_CHKS == "true")){
if( !empty($userdata["mailadds"]) ){
if(filter_var($userdata["mailadds"], FILTER_VALIDATE_EMAIL)){
- $mail_title = "お使いの".htmlspecialchars($serversettings["serverinfo"]["server_name"], ENT_QUOTES, 'UTF-8')."アカウントはBANされました";
- $mail_text = "".$userdata["username"]."(".$userdata["userid"].")さん いつもuwuzuをご利用いただきありがとうございます。 この度、ご利用のアカウント(".$userdata["userid"].")が".htmlspecialchars($serversettings["serverinfo"]["server_name"], ENT_QUOTES, 'UTF-8')."管理者によりBAN(削除)されたためお知らせいたします。 今後は今までご利用いただいた".htmlspecialchars($serversettings["serverinfo"]["server_name"], ENT_QUOTES, 'UTF-8')."アカウントは利用できません。 ".htmlspecialchars($serversettings["serverinfo"]["server_name"], ENT_QUOTES, 'UTF-8')."サーバー上から今までご利用いただいていたアカウントの情報は削除されたためログインなどもできません。 ご理解とご協力のほどよろしくお願いします。";
+ $mail_title = "お使いの".htmlentities($serversettings["serverinfo"]["server_name"], ENT_QUOTES, 'UTF-8')."アカウントはBANされました";
+ $mail_text = "".$userdata["username"]."(".$userdata["userid"].")さん いつもuwuzuをご利用いただきありがとうございます。 この度、ご利用のアカウント(".$userdata["userid"].")が".htmlentities($serversettings["serverinfo"]["server_name"], ENT_QUOTES, 'UTF-8')."管理者によりBAN(削除)されたためお知らせいたします。 今後は今までご利用いただいた".htmlentities($serversettings["serverinfo"]["server_name"], ENT_QUOTES, 'UTF-8')."アカウントは利用できません。 ".htmlentities($serversettings["serverinfo"]["server_name"], ENT_QUOTES, 'UTF-8')."サーバー上から今までご利用いただいていたアカウントの情報は削除されたためログインなどもできません。 ご理解とご協力のほどよろしくお願いします。";
send_html_mail($userdata["mailadds"],$mail_title,$mail_text,"../");
}
@@ -570,13 +570,13 @@ require('../logout/logout.php');