Added Summernote WYSIWYG to client portal

This commit is contained in:
johnnyq 2023-03-12 11:02:09 -04:00
parent c9dfb1ef6a
commit 58d058e62c
5 changed files with 25 additions and 3 deletions

View File

@ -18,4 +18,24 @@
<script src="../plugins/jquery/jquery.min.js"></script>
<!-- Bootstrap 4 -->
<script src="../plugins/bootstrap/js/bootstrap.bundle.min.js"></script>
<script src="../plugins/bootstrap/js/bootstrap.bundle.min.js"></script>
<script src="../plugins/summernote/summernote-bs4.min.js"></script>
<script>
// Summernote
$('.summernote').summernote({
toolbar: [
['style', ['style']],
['font', ['bold', 'underline', 'clear']],
['fontname', ['fontname']],
['color', ['color']],
['para', ['ul', 'ol', 'paragraph']],
['table', ['table']],
['insert', ['link', 'picture', 'video']],
['view', ['codeview']],
],
height: 200
});
</script>

View File

@ -24,6 +24,8 @@ header("X-Frame-Options: DENY");
<!-- Theme style -->
<link rel="stylesheet" href="../dist/css/adminlte.min.css">
<link href="../plugins/summernote/summernote-bs4.min.css" rel="stylesheet">
<!-- Google Font: Source Sans Pro -->
<link href="https://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,400i,700" rel="stylesheet">
</head>

View File

@ -76,9 +76,9 @@ if (isset($_GET['id']) && intval($_GET['id'])) {
<form action="portal_post.php" method="post">
<input type="hidden" name="ticket_id" value="<?php echo $ticket_id ?>">
<div class="form-group">
<textarea class="form-control" name="comment" placeholder="Add comments.."></textarea>
<textarea class="form-control summernote" name="comment" placeholder="Add comments.."></textarea>
</div>
<button type="submit" class="btn btn-primary" name="add_ticket_comment">Save reply</button>
<button type="submit" class="btn btn-primary" name="add_ticket_comment">Reply</button>
</form>
<?php }