twentyfourhoursmedia/comments-work 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

twentyfourhoursmedia/comments-work

Composer 安装命令:

composer require twentyfourhoursmedia/comments-work

包简介

An easy to use comment plugin for Craft CMS 3

README 文档

README

An easy to use and straightforward commenting plugin for Craft CMS 3.x. Allow users to post comments to your content, and moderate them from the dashboard.

Documentation

Read all at our online documentation resource

Comments Work Overview

  • Add user comments to any type of element, such as users and content items
  • Get a nice overview of submitted comments in the CP
  • Moderation: delete, approve or mark as spam in the CP
  • Moderation: modify comment contents in the CP
  • Comment forms are signed so malicious users cannot submit comments to arbitrary content

Usage

Quick example how code would look on the front-end. Read more at:

{# @var commentsWork \twentyfourhoursmedia\commentswork\services\CommentsWorkService #}
{% set commentsWork = craft.commentsWork.service %}

<div id="comments">
    <br/>
    <p>{{  commentsWork.countComments(entry) }} comments</p>

    {% set comments = commentsWork.fetchComments(entry, 0, 10) %}
    {% for comment in comments %}
        {# @var comment \twentyfourhoursmedia\commentswork\models\CommentModel #}
        <div class="card card bg-light">
            <div class="card-body">
                <div class="row">
                    <div class="col-md-2">
                        <img src="https://image.ibb.co/jw55Ex/def_face.jpg" class="img img-rounded img-fluid" width="64">
                        <p class="text-secondary text-center">{{ comment.dateCreated | date }} {{ comment.dateCreated | date('H:i') }}</p>
                    </div>
                    <div class="col-md-10">
                        {%- if comment.user %}<p><a href="https://maniruzzaman-akash.blogspot.com/p/contact.html"><strong>{{ comment.user.friendlyName }}</strong></a></p>{% endif -%}
                        {%- if comment.title is not empty %}
                            <p><strong>{{ comment.title }}</strong></p>
                        {% endif -%}
                        {%- if comment.comment is not empty %}
                            <p>
                                {{ comment | commentAsHtml }}
                            </p>
                        {% endif -%}
                    </div>
                </div>
            </div>
        </div>
        <br/>
    {% endfor %}
</div>

Requirements

This plugin requires Craft CMS 3.0 or later, and works best with the PRO edition. (Other editions do not support users)

Installation

To install the plugin, follow the instructions at https://io.24hoursmedia.com/comments-work/installation

Configuring Comments Work

There are two configuration options. In the Admin CP, go to 'Settings' -> 'Comments Work'. Read more at https://io.24hoursmedia.com/comments-work/configuration

  • 'auto approve comments' - if enabled, comments are shown immediately on the site.This bypasses the moderation. NOT RECOMMENDED WHEN ANONYMOUS COMMENTS ARE ENABLED!
  • 'Allow anonymous comments' - allows anonymous users to post comments.

Brought to you by 24hoursmedia

Logo by https://www.iconfinder.com/ReactiveDoodlesApp

统计信息

  • 总下载量: 244
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: proprietary
  • 更新时间: 2018-08-14

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固