Try to fix textarea
This commit is contained in:
@@ -1,3 +1,30 @@
|
||||
<style>
|
||||
#comment {
|
||||
resize: none;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
#comment-count {
|
||||
right: 3px;
|
||||
bottom: 0;
|
||||
}
|
||||
|
||||
@supports selector(:has(html)) {
|
||||
.was-validated .position-relative:has(:invalid)~.invalid-feedback {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.was-validated :invalid~.invalid-feedback {
|
||||
display: none !important;
|
||||
}
|
||||
}
|
||||
|
||||
@supports not selector(:has(html)) {
|
||||
.was-validated :invalid~#comment-count {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
<form action="comment.php" method="post" class="needs-validation row m-0" novalidate>
|
||||
<div class="col">
|
||||
<h4 class="mb-3">Leave a Comment!</h4>
|
||||
@@ -15,8 +42,11 @@
|
||||
</div>
|
||||
<div class="mb-3">
|
||||
<div class="position-relative">
|
||||
<textarea class="form-control" id="comment" name="comment" rows="3" maxlength="250" required placeholder="Comment here"></textarea>
|
||||
<small class="text-muted position-absolute" id="comment-count" style="right: 20px; bottom: 0;">
|
||||
<textarea class="form-control" id="comment" name="comment" maxlength="250" required placeholder="Comment here"></textarea>
|
||||
<div class="invalid-feedback">
|
||||
Please enter text.
|
||||
</div>
|
||||
<small class="text-muted position-absolute" id="comment-count">
|
||||
0/250
|
||||
</small>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user