Developed with love by KnpLabs Hire us for your project!
295

FOSCommentBundle

by FriendsOfSymfony

Threaded comments for Symfony2

FOSCommentBundle

The FOSCommentBundle adds support for a comment system in Symfony2. Features include:

  • Manages trees of comments
  • Can include comment threads in any page
  • Compatible with any persistence backend. Doctrine2 mongodb-odm and ORM are implemented.
  • Configurable sorting of the comment tree
  • REST api
  • Extensible through events fired during the comment lifecycle
  • Optional use of Symfony2 Acl to protect comments
  • Optional integration with FOS\UserBundle
  • Optional integration with Akismet_
  • Optional markup parser support (eg HtmlPurifier or php-sundown)

Note:

For users of Symfony2.0, you must use the 1.x branch. Master is no longer
compatible with Symfony2.0.

For users of Symfony2.1, you must use 2.0.0 or higher of this bundle.

Build Status

Documentation

The bulk of the documentation is stored in the Resources/doc/index.md
file in this bundle:

Read the Documentation

Installation

All the installation instructions are located in documentation.

License

This bundle is under the MIT license. See the complete license in the bundle:

Resources/meta/LICENSE
The MIT license

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is furnished
to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
fos_comment:
db_driver: ~ # Required
model_manager_name: ~
form:
comment:
type: fos_comment_comment
name: fos_comment_comment
thread:
type: fos_comment_thread
name: fos_comment_thread
commentable_thread:
type: fos_comment_commentable_thread
name: fos_comment_commentable_thread
delete_comment:
type: fos_comment_delete_comment
name: fos_comment_delete_comment
vote:
type: fos_comment_vote
name: fos_comment_vote
class: # Required
model: # Required
comment: ~ # Required
thread: ~ # Required
vote: ~
acl: []
acl_roles:
comment:
create: IS_AUTHENTICATED_ANONYMOUSLY
view: IS_AUTHENTICATED_ANONYMOUSLY
edit: ROLE_ADMIN
delete: ROLE_ADMIN
thread:
create: IS_AUTHENTICATED_ANONYMOUSLY
view: IS_AUTHENTICATED_ANONYMOUSLY
edit: ROLE_ADMIN
delete: ROLE_ADMIN
vote:
create: IS_AUTHENTICATED_ANONYMOUSLY
view: IS_AUTHENTICATED_ANONYMOUSLY
edit: ROLE_ADMIN
delete: ROLE_ADMIN
template:
engine: twig
service:
manager:
comment: fos_comment.manager.comment.default
thread: fos_comment.manager.thread.default
vote: fos_comment.manager.vote.default
acl:
comment: fos_comment.acl.comment.security
thread: fos_comment.acl.thread.security
vote: fos_comment.acl.vote.security
form_factory:
comment: fos_comment.form_factory.comment.default
commentable_thread: fos_comment.form_factory.commentable_thread.default
delete_comment: fos_comment.form_factory.delete_comment.default
thread: fos_comment.form_factory.thread.default
vote: fos_comment.form_factory.vote.default
spam_detection:
comment: ~
sorting:
default: date_desc
markup: ~
  • Allow symfony 2.3
    By merk, 18 days ago
  • Allow symfony 2.3
    By merk, 18 days ago
  • Allow symfony 2.3
    By merk, 18 days ago
  • Allow symfony 2.3
    By merk, 18 days ago
  • Allow symfony 2.3
    By merk, 18 days ago
  • Allow symfony 2.3
    By merk, 18 days ago
  • Allow symfony 2.3
    By merk, 18 days ago
  • Allow symfony 2.3
    By merk, 18 days ago
  • Allow symfony 2.3
    By merk, 18 days ago
  • Allow symfony 2.3
    By merk, 18 days ago
  • Allow symfony 2.3
    By merk, 18 days ago
  • Allow symfony 2.3
    By merk, 18 days ago
  • Allow symfony 2.3
    By merk, 18 days ago
  • Allow symfony 2.3
    By merk, 18 days ago
  • Allow symfony 2.3
    By merk, 18 days ago
  • Allow symfony 2.3
    By merk, 18 days ago
  • Allow symfony 2.3
    By merk, 18 days ago
  • Allow symfony 2.3
    By merk, 18 days ago
  • Merge pull request #363 from benbender/master
    By stof, 1 month ago
  • Fix missing rename
    By Benjamin Bender, 1 month ago
  • Implement ConfigurationInterface
    By Benjamin Bender, 1 month ago
  • Merge pull request #357 from XWB/jquery-1.9-fix
    By merk, 1 month ago
  • Trim ajax response string
    By XWB, 1 month ago
  • Merge pull request #353 from ajbdev/patch-1
    By stof, 2 months ago
  • Update 9b-sundown_markdown_parser.md
    By ajbdev, 2 months ago
  • Update dependency constraints
    By merk, 2 months ago
  • Move temporary stability dependency to require-dev
    By merk, 2 months ago
  • Merge pull request #351 from tarjei/deprecated-2
    By stof, 2 months ago
  • Fix test error, also update doctrine dev-dependency (composer would barf if not).
    By tarjei, 2 months ago
  • Update validations to reflect deprecated MinLength in 2.2.
    By frisvold, 2 months ago