From 8a67f7016658abffeae99f3f543e022697117d67 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zden=C4=9Bk=20Borovec?= Date: Tue, 30 Apr 2024 02:38:50 +0200 Subject: [PATCH] show comment response chkbox --- assets/common/styles.css | 60 +++++++++++++++++++++------------------ docs/www/blog/article.php | 34 +++++++++------------- 2 files changed, 45 insertions(+), 49 deletions(-) diff --git a/assets/common/styles.css b/assets/common/styles.css index a233231..c21d08e 100755 --- a/assets/common/styles.css +++ b/assets/common/styles.css @@ -267,7 +267,7 @@ code { margin-left: 0.5em; } -.comment .comment-own-wrapper{ +.comment-own-wrapper{ background-image: url("http://assets.zdenekborovec-dev.cz/common/planks_dark_tile.png"); background-repeat: repeat; background-color: black; @@ -275,37 +275,41 @@ code { border-bottom: 1px solid black; } -.comment .comment-child-wrapper{ +.comment-child-wrapper{ border-left: 1px solid black; } -.comment .comment-metadata, .comment .comment-content { - padding: 0.5em; -} - -.comment-metadata { - width: 100%; -} - -.comment-metadata tr, .comment-metadata td{ - border: none; - padding-bottom: 0px; -} - -.comment-metadata .comment-author { - text-align: left; -} - -.comment-metadata .comment-date { - text-align: right; -} - -.comment-metadata .comment-id { - text-align: right; - color: black; -} - .comment-box { width: 100%; height: 5em; } + +.comment-author { + margin: 0.5em; + display: inline-block; +} + +.comment-date { + margin: 0.5em; + display: inline-block; +} + +.checkbox-button { + margin: 0.5em; + display: inline-block; + background-image: url("http://assets.zdenekborovec-dev.cz/common/planks_light_tile.png"); + background-repeat: repeat; + background-color: white; + color: black; + border: 1px solid black; + cursor: pointer; +} + +input[type=checkbox]:checked ~ .comment-response{ + display: block; +} + +.comment-response { + display: none; + border-top: double black; +} diff --git a/docs/www/blog/article.php b/docs/www/blog/article.php index 0d04e3b..c9dd152 100644 --- a/docs/www/blog/article.php +++ b/docs/www/blog/article.php @@ -21,31 +21,24 @@ class BlogpostComment printf("
- - - - - - - - - -
- By: %s - - On: %s -
- - %s -
+ By: %s + On: %s + +
%s
+
+ peepeepoopoo +
", $this->poster_name, date("Y-m-d H:i", - strtotime($this->timestamp)), $this->comment_id, $this->content); + strtotime($this->timestamp)), $this->comment_id, $this->comment_id, + $this->content); if($this->children != null) { for($i = 0; $i < count($this->children); $i++) @@ -326,11 +319,10 @@ printf("

Comments:

-
- +
- +
", htmlspecialchars($_SERVER["PHP_SELF"]), $blogId);