Purpose
Interact is a simple PHP open-source comment system that can be added to any website in minutes to improve interactivity and user's involvement. Client-side, it is very lightweight (<6KB CSS and JS combined) and intuitive (no logins, no cookies,...). Server-side, it is very easy to setup, manage and even customize to fit your needs.
Similarly to its older brother HashOver, Interact does not use an SQL database but stores comments as XML files. Many third-party comment systems like Disqus, IntenseDebate, Livefyre, Facebook Comments and Google+ Comments, suffer from these problems and impose them and many restrictions onto their users, meaning you and your website's visitors.
Features
- Fast and convenient for your users with responsive design.
- Very simple setup: no database to configure, just install it and add 2 lines of PHP where you want your comment section to be.
- Customizable style and behavior to match the look & feel of your website.
- Anti-Spam system using Google's reCAPTCHA v2 (optional).
- Pure JS (no JQuery required).
- Secure by design.
- New: Inline markdown syntax support in comments (bold, italics,
strikethroughandinline code
)
Installation and setup
- Download Interact on GitHub.
- Extract it under your website's root.
- Customize Interact's behavior to your needs by editing the /lib/Interact_PHP/settings.php file.
- Give the directory that will contain the comments the 777 permission (
chmod 777 path/to/Interact_PHP/Comments
).
Hurray, Interact is ready to go! To add a comment section to a page, just insert the following PHP:
<?php
include_once($_SERVER['DOCUMENT_ROOT'].'/lib/Interact_PHP/Interact_PHP.php');
\Interact_PHP\Interact_PHP();
?>
Parameters and cutomization
All of the parameters of Interact are in the settings.php file. There are a lot of comments to assist you in the configuration process.
If you want to add your own style, copy an existing CSS file to get started... and commit it on GitHub if you want to contribute to Interact's ongoing developpement!
Troubleshooting
This section describes the various problems you may encounter while installing/using Interact. If you don't find a solution here, please add a GitHub issue.
- I can't add comments
You should check the permissions of the folder containing the comments (Interact/Comments by default). The PHP user must be able to write there. Setting 777 works (chmod -R 777 Comments
).
For some reason, the libxml PHP library was not enabled on PHP7 on one of my servers. Installing it fixed the issue (apt-get install php7.0-xml
, reboot when completed).
- The CSS does not load
The path of the library relative to the root of your website is probably incorrect. Make sure it matches with the value in settings.php. By default, it is /lib/Interact.
- I am getting reCAPTCHA errors even after checking the box
You need to make sure that your reCAPTACHA public and secret keys are correct. Interact uses reCAPTCHA v2. More info at https://developers.google.com/recaptcha/docs/display
Future features
- A simple admin interface to manage comments (Work In Progress)
- A tag to identify the admin (Work In Progress)
Author: Charles Grassin
What is on your mind?
#1 leo
on April 11 2019, 2:39
#2 兔
on April 11 2019, 2:44
#3 Charles
on May 12 2019, 2:57
#4 dfaff
on July 31 2019, 5:28
#5 DaAds
on August 5 2019, 18:01
#6 Aaa
on August 6 2019, 11:21
#7 Vlad
on August 11 2019, 14:15
#8 hghgh
on August 30 2019, 3:02
#9 ggggggggggggggggg
on August 30 2019, 3:03
#10 ,iş,ş
on December 10 2019, 16:16
#11 Wsad
on December 14 2019, 16:33
#12 :kn
on December 17 2019, 16:55
#13 lkj
on December 17 2019, 16:55
#14 Tester
on March 5 2020, 21:38
#15 Rob
on March 26 2020, 12:05
#16 Tester
on April 7 2020, 10:26
#17 Tester
on April 7 2020, 10:28
#18 NotARussianSpy
on October 27 2020, 16:13
#19 strikethrough
on October 27 2020, 16:15
#20 Charles
on April 16 2021, 22:01