NAME

    Kwiki::Comments - Post comments to a page

DESCRIPTION

    Kwiki::Comments is a Kwiki plugin that allow anyone to leave comments
    to a Page, just like Slash comments or MT comments. To use this plugin,
    simply install Kwiki, and this module from CPAN, and do:

        # echo 'Kwiki::Comments' >> plugins
        # kwiki -update

    Currently you'll need to have DBD::SQLite module installed to use this
    module. Maybe in the future, we can support more kinds of database
    back-end.

    And now your site is ready to have comments. But, comments are not
    shown automatically. You'll have to append this line:

        {comments}

    To whatever pages that are allow comment.

    The basic idea is that, some wiki pages can be protected, only admin
    can edit them. On those protected pages, comments becomes the only way
    for anybody to give feedbacks, but sometimes you don't even want a
    feedback. That's why you'll need to clearly specify if you want a
    comment form attach to the page, or not.

FOR KWIKI ADMINS

    Pull updated templates of Kiwki::Comments by doing this on servers that
    hosts kwiki:

        kiwki -update /path/to/kwiki/

 NOTES for 1.00

    Kwiki::Comment before 1.00 store perhaps user input in it's database
    (sqlite files) without much validation process.

    These extra validation rules are included in 1.00:

        "text" and "author" are no-longer pass-through
         but rendered with HTML tag-filter.
    
        "email" is verified upon rendering as well as storing, to ensure
         only 1 valid email address string is contained. Other cases are ignored.
    
        "url" is verifed upon rendering as well as storing, to ensure
         a valid URI string is contained. Other cases are ignored.

    However, existing data in database (sqlite files) are still containing
    their historical data and is not automatically removed by the upgrade
    of Kwiki::Comment, and it'll never be dealt with this way.

    Kwiki::Common 1.00 starts storing only user comments with valid email
    address as well as valid https URLs. You may cleanup existing entries
    using this simple rule. But even if you don't, invalid values are now
    ignroed treated as if they are empty strings.

    Should you, a kwiki admmin, decide to manually do so, these are the
    sqlite files to go through:

        find /path/to/kwiki/plugin/comments/ -name '*.sqlt'

    The only table in those file is created with this trivial schema:

        CREATE TABLE comments (author,email,url,text)

    Those should enough leads for start digging.

AUTHOR

    Kang-min Liu <gugod@gugod.org>

COPYRIGHT AND LICENSE

    Copyright (c) 2026 Kang-min Liu <gugod@gugod.org>.

    This program is free software; you can redistribute it and/or modify it
    under the same terms as Perl itself.

    See <http://www.perl.com/perl/misc/Artistic.html>

