diff --git a/docs/css/main.css b/docs/css/main.css index f929b8b..e865a94 100644 --- a/docs/css/main.css +++ b/docs/css/main.css @@ -22,6 +22,10 @@ body { margin-top: 0 } +pre { + white-space: pre-wrap; +} + .banner { justify-content: center; margin-bottom: calc(-1*var(--elem-height)) @@ -49,17 +53,22 @@ body { .banner, .banner-background, -.content { +.content, +.comment { width: var(--elem-width) } .avatar { display: flex; - justify-content: space-between; - width: var(--elem-width); + justify-content: space-around; + width: 300px; align-items: center; } +.banner pre { + width: var(--elem-width); +} + .avatar-img { width: 50px; height: 50px; @@ -78,7 +87,8 @@ body { .form-button, .form-input, -.form { +.form, +.comment { border: solid var(--gray) 3px; background: var(--black); border-radius: var(--border-radius); diff --git a/docs/index.php b/docs/index.php index 3036608..a188438 100644 --- a/docs/index.php +++ b/docs/index.php @@ -1,10 +1,53 @@ prepare("INSERT INTO main.comment (username, targetType, targetId, date, content, id) VALUES (?,?,?,?,?,?)"); + $stmt->execute([$username,"root","root",microtime(true) - $ref,$postie,bin2hex(random_bytes(16))]); + } + page_header(); -?> + + $form_message = post_handler(); + + // todo: make this not look weird + if ($username) { + form("Broadcast your thoughts...", $form_message, array( + array('key' => 'Post', 'type' => 'textarea', 'name' => 'post', 'default' => '') + )); + } + + $stmt = $db->prepare("SELECT * FROM comment ORDER BY date DESC"); + $stmt->execute([]); + + $posts = $stmt->fetchAll(PDO::FETCH_DEFAULT); -
Very barren.
- - +