Interact PHP - comment system

Code - 17-08-2018

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.

Interact PHP with the modern interface Interact PHP with the default theme

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 other restrictions onto their users, meaning you and your website's visitors.

Features

  • No dependency.
  • 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.
  • Easily 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.
  • Inline Markdown syntax support in comments (bold, italics, strike-through and inline code) (can be disabled).
  • Open-source (MIT license).
  • W3C compliant and follows accessibility rules.

Installation and setup

Requirements: PHP≥5, php-xml.

  1. Download/clone Interact on GitHub.
  2. Put the "Interact_PHP" folder under your website's root (or relocate the folder where you want and change the LIBRARY_ROOT setting accordingly).
  3. Optional: customize Interact's behavior to your needs by editing the Interact_PHP/settings.php file and/or the Interact_PHP/strings.xml.
  4. Give the directory that will contain the comments 777 permission (chmod -R 777 path/to/interact_php/Comments). Alternatively, chown the folder to the user that is configured to execute PHP scripts as, for example "www-data". And then simply give the "path/to/Interact_PHP/Comments" directory permissions "755".

Hurray, Interact is ready to go! To add a comment section to a page, just insert the following PHP in any page:

<?php 
    include_once($_SERVER['DOCUMENT_ROOT'].'/interact_php/Interact_PHP.php');
    \Interact_PHP\Interact_PHP("<some-id-such-as-article-title>"); 
?>

The parameter <some-id-such-as-article-title> is what will be used to associate the comments with this form. If you call \Interact_PHP\Interact_PHP() without an argument, it creates an ID from the URL, but this is not recommended.

You can call \Interact_PHP\Interact_PHP() multiple times per page if you need multiple comment forms (e.g. a page with several articles).

Parameters and customization

All of the core parameters of Interact are in the settings.php file. There are a lot of comments to assist you in the configuration process. Some of them, like enabling reCAPTCHA are highly recommended.

Look and feel

Several CSS files are included with Interact PHP. 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 development!

Interact PHP with various CSS Various included themes with Interact PHP

Internationalization

Interact PHP supports full internationalization: all user-visible strings are stored in a "string.xml" file. You can edit this file to match your website or add translations, and call \Interact_PHP\Interact_PHP("<some-id-such-as-article-title>", "language") with another parameter "language" that is the desired language to display.

If you need a single display language, you can just customize the "default" language.

Admin interface

If you set up a value for ADMIN_PASSWORD, Interact PHP enables a very simple admin interface that allows to delete and promote comments (to show an "Author" badge).

Interact PHP's admin interface The administration interface for Interact PHP

It is accessible from the url: https://your_website_url/path/to/interact_php/admin/admin.php.

Note about security: Interact PHP only stores a hash of the password, and the absolute worst that can happen if a bad actor were to gain access would be the ability to remove comments, which is negated by doing backups of the comment files (anyway recommended). Regardless, I would highly advise only enabling this admin interface if the two conditions below are met:

  1. Your website uses HTTPS,
  2. You either enabled the reCAPTCHA anti-spam system for Interact PHP and/or you have another way to prevent brute-forcing on your website.

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).

If the libxml PHP library is not enabled, installing should fix the issue (e.g. sudo apt-get install php-xml, restart Apache 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 /interact_php.

  • 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/work in progress

This is the list of future features, by priority:

  • New feature: collapsible comment box if the comment box height is more than N pixels or N comments
  • New feature: optional hidden email field to allow the webmaster to contact users

Please submit a GitHub issue for feature requests or bug reports.

License

This library is published under MIT license.

Auteur :


What is on your mind?

  • #1 leo

    nice!

    on April 11 2019, 2:39

  • #2

    Simple and useful 测试中文

    on April 11 2019, 2:44

  • #3 Author Charles

    Test comment:
    This is a Markdown syntax test.
    Markdown is bad.
    [MD XSS](javascript:alert("xss"))
    <script>alert("XSS test!");</script>

    on May 12 2019, 2:57

  • #4 Pierrot

    Hi Charles,
    and thank you for sharing InteractPHP.
    There's a little error at line 7 in setting.php : it's written interact
    php instead of interact_PHP...
    Unfortunatly, I couldn't make it work anyway because my site is on a vm behind Nginx reverse proxy. This gives me an error of mixed content with https when I click on "Submit". It 's written "Sending message..." and no more...
    Do you have any advice to help me to fix this little problem ?
    Thanks on advance.

    on April 3 2023, 17:33

  • #5 Drozsam

    <a href=https://megaremont.pro/grodno-restavratsiya-vann>restauration de l'émail des bains</a>

    on July 9 2023, 4:47

  • #6 KennethCoida

    <a href=https://restavratsiyavann.com/gorodets/>Réparation des baignoires</a>

    on July 20 2023, 23:55

  • #7 Tilly

    What's up to every one, it's actually a good for me to pay
    a visit this website, it consists of valuable Information. darknet markets 2023
    https://mydarkmarket.com

    on August 19 2023, 1:46

  • #8 http://kheymomo.blogspot.com/

    do you already know the vaccines you should give to your new babies come on and visit my site to find out
    http://kheymomo.blogspot.com/

    on September 27 2023, 11:10

  • #9 http://kheymomo.blogspot.com/

    do you already know the vaccines you should give to your new babies come on and visit my site to find out
    http://kheymomo.blogspot.com/

    on September 27 2023, 11:10

  • #10 Verla

    Hi I am so delighted I found your web site, I really found you
    by mistake, while I was looking on Bing for something else, Nonetheless I am here
    now and would just like to say kudos for a remarkable post and
    a all round exciting blog (I also love the theme/design),
    I don't have time to read through it all at the moment but I
    have saved it and also added your RSS feeds, so when I have time I will be
    back to read much more, Please do keep up the great job. darknet marketplace https://mydarkmarket.com

    on October 29 2023, 21:11

  • #11 Triarne

    This means that the ratio of S R plasma concentrations decreases with time after each dose <a href=http://cial.cfd>generic cialis online</a>

    on November 3 2023, 12:34

  • #12 RobertSnork

    https://roomstyler.com/users/carrentallimassol

    on December 6 2023, 17:25

  • #13 Brooche

    Upon palpation abdomen was soft and non distended <a href=https://tadalafi.sbs>buying cialis generic</a> Even if there is malabsorption, about 1 to 2 of an oral dose is absorbed by passive diffusion; this allows for absorption of 10 to 20 micrograms of vitamin B12, when 1 to 2 mg of vitamin B12 are consumed daily

    on January 2 2024, 4:47

  • #14 russian teacher porn


    As a Newbie, I am continuously exploring online for articles that can be of assistance to me.
    My website: <a href="http://google.co.jp/url?q=https://russkoeporevo.pro/cat-massage/">Порно массаж</a>

    on January 25 2024, 20:43

  • #15 массаж секс


    As a Newbie, I am continuously exploring online for articles that can be of assistance to me.
    My website: <a href="http://berkat.ru/redirect?url=https://russkoeporevo.pro/cat-students/">порно студенты</a>

    on January 25 2024, 20:45

  • #16 русское порно


    As a Newbie, I am always searching online for articles that can help me. Thank you
    My website: <a href="http://eastandpartners.com/?URL=https://russkoeporevo.pro/categories/">русский секс по категориям</a>

    on January 26 2024, 9:15

  • #17 секс по пьяне


    A round of applause for your article. Much thanks again.
    My website: <a href="http://images.google.pt/url?q=https://russkoeporevo.pro/cat-students/">порно студентки русское</a>

    on January 27 2024, 14:10

  • #18 Порно массаж


    I am incessantly thought about this, thanks for posting.
    My website: <a href="https://pinelakes.com/?URL=https://russkoeporevo.pro/cat-porno-s-uchitelem/">русское порно с преподавателем</a>

    on January 27 2024, 14:29

  • #19 секс на массаже


    Thanks-a-mundo for the post.Really thank you! Awesome.
    My website: <a href="http://www.google.vu/url?q=https://russkoeporevo.pro/cat-massage/">секс масаж</a>

    on January 27 2024, 23:10

  • #20 массаж порно


    Wohh precisely what I was searching for, regards for putting up.
    My website: <a href="http://3h.kz/go.php?url=https://russkoeporevo.pro/categories/">порно русское по категориям</a>

    on January 28 2024, 4:14

  • #21 ебут пьяных


    A lot of blog writers nowadays yet just a few have blog posts worth spending time on reviewing.
    My website: <a href="http://www.seniorclassaward.com/?URL=russkoeporevo.pro/cat-porno-s-uchitelem/">порно учитель русское</a>

    on January 29 2024, 8:57

  • #22 порно hd план


    Definitely, what a great blog and revealing posts, I definitely will bookmark your site. Best Regards!
    My website: <a href="https://pornobomba.top/categories/porno-milf/">секс зрелых милф</a>

    on February 6 2024, 14:08

  • #23 Triarne

    Comparison of Pediatric Use of IV and Oral N Acetylcysteine <a href=http://cialiss.buzz>cialis order online</a> The spiritual power in Heimu is body burst out, and then his figure flashed, and he killed Huang Qing

    on February 7 2024, 12:32

  • #24 DStMTtRwc

    What are the risks and benefits of hormone therapy <a href=https://propecias.buzz>mail order propecia</a> Nevertheless, several groups have demonstrated abnormalities in cardiac morphology or function in patients with PAL that appear to be out of proportion to the elevation in blood pressure and which improved following specific treatment of PAL

    on February 9 2024, 2:35

  • #25 отец ебет дочь


    Respect to post author, some fantastic information
    My website: <a href="https://theporndude.in/cat-russkie-mamki/">русское порно инцест мама и сын</a>

    on February 9 2024, 13:22

  • #26 Brooche

    Methadone 50 or 60 mg mean 56 mg, 100 and 150 of normal dose <a href=https://finasteride.one>buy cheap propecia</a> All Acinetobacter isolates were identified as A

    on February 9 2024, 18:15

  • #27 KgJePxZi

    <a href=http://vpriligys.buzz>priligy price</a> To further investigate the effect of MCM7 depletion in treatment of RB proficient and RB deficient tumors, AdE7 adenoviruses, which express human papillomavirus HPV E7 oncoprotein and degrade RB protein, 27, 28, 29 was used to infect RB proficient U2OS and SiHa cells; and AdPSM RB adenoviruses, which express an active allele of RB protein, 30 was used to restore active RB in RB deficient SaOS2 and C33A cells

    on February 10 2024, 1:33

  • #28 лизание попки


    This site definitely has all of the information I needed about this subject
    My website: <a href="https://narodnoeporno.pro/categories/russkoe-domashnee-porno/">русское любительское порно</a>

    on February 10 2024, 7:36

  • #29 AWemKtV

    00263, respectively did not reach significance after Bonferroni Holm s correction <a href=http://cials.cfd>cialis generic name</a>

    on February 10 2024, 12:15

  • #30 Сквирт


    I reckon something truly special in this website.
    My website: <a href="https://pornobomba.top/categories/porno-babushki/">смотреть порно старушки</a>

    on February 11 2024, 15:01

  • #31 sex camera


    A round of applause for your article. Much thanks again.
    My website: <a href="https://pornobomba.top/categories/porno-s-sestroi/">трахает сводную сестру</a>

    on February 11 2024, 15:19

  • #32 голая сосет


    Major thanks for the article post. Much thanks again.
    My website: <a href="https://narodnoeporno.pro/categories/skvirt/">сквирт онлайн</a>

    on February 12 2024, 12:20

  • #33 порно азиаточки


    Thanks-a-mundo for the post.Really thank you! Awesome.
    My website: <a href="https://theporndude.in/cat-porno-transi/">жесткое порно трансвеститов</a>

    on February 12 2024, 12:37

  • #34 DAdtNXBp

    <a href=http://viagr.sbs>what mg does viagra come in</a> 97 for Group B and quality of life as measured by the ParEnt Qol scale was 21 for Group A versus 30 for Group B, which indicates a higher quality of life for those in Group A

    on February 12 2024, 19:19

  • #35 shhsgZ

    To confirm that A 2A receptor agonism can deplete CD11c T bet hi B cells, we treated E <a href=http://levitr.buzz>acheter levitra 20mg pharmacie</a> Continuous infusion of CXCR4 inhibitors therefore represents a novel pharmacologic model of reversible mobilization and in vivo expansion of HSPCs and may serve as a strategy to restore the HSPC pool after cytotoxic damage or as a method of chemotherapy sensitization of hematologic malignancies

    on February 13 2024, 10:50

  • #36 Triarne

    <a href=http://finasteride.one>buy finpecia online</a> 992; figure 2

    on February 13 2024, 22:08

  • #37 qLirvZv

    Krunic A, Ciurea A, Scheman A <a href=https://propeci.cfd>propecia online no prescription</a> 02 22 1 HUV EC C 0

    on February 15 2024, 9:08

  • #38 вылизал анал


    I gotta favorite this site it seems very beneficial handy
    My website: <a href="https://pornobomba.top/categories/bolshaya-zhopa/">Большая жопа</a>

    on February 15 2024, 17:56

  • #39 голые армянки


    This site definitely has all of the information I needed about this subject
    My website: <a href="https://theporndude.in/cat-porno-podrostkov/">порно юные подростки</a>

    on February 15 2024, 18:35

  • #40 Triarne

    <a href=https://viagrax.lol>viagra farmacia online</a> How can He s spirituality not see that there is also a contradiction in her heart

    on February 15 2024, 20:54

  • #41 анал измена


    Thanks-a-mundo for the post.Really thank you! Awesome.
    My website: <a href="https://pornobomba.top/categories/porno-s-rizhimi-devushkami/">русское порно рыжие</a>

    on February 16 2024, 12:01

  • #42 Brooche

    <a href=https://tadalafil.top>buy cialis online using paypal</a> Cells were washed in PBS and mounted in Vectashield Vector Labs

    on February 17 2024, 0:51

  • #43 секс с докторшей


    A lot of blog writers nowadays yet just a few have blog posts worth spending time on reviewing.
    My website: <a href="https://narodnoeporno.pro/categories/porno-s-uchitelem/">порно студентки</a>

    on February 17 2024, 10:26

  • #44 вылизал письку


    A lot of blog writers nowadays yet just a few have blog posts worth spending time on reviewing.
    My website: <a href="https://pornobomba.top/categories/uprugie-siski/">порно упругая грудь</a>

    on February 18 2024, 10:38

  • #45 порно пов


    Muchos Gracias for your article.Really thank you! Cool.
    My website: <a href="https://narodnoeporno.pro/categories/anal-porno/">трахает в попу</a>

    on February 18 2024, 11:27

  • #46 Zcivme

    MCF7 TAMR Tet shH19 xenografts were established in 5 week old nude mice Shanghai SLAC Laboratory Animal Corporation by inoculating 1 10 7 cells together with 50 Matrigel, BD Biosciences into the abdominal mammary fat pad <a href=http://levitr.buzz>cialis pfizer levitra comparaison</a>

    on February 18 2024, 18:11

  • #47 Brooche

    Furthermore, during the first week after discharge, symptoms scores improved more quickly in the ICS group 8 <a href=http://bviagra.mom>what is a viagra pill</a>

    on February 19 2024, 3:16

  • #48 DXdTbJ

    <a href=https://finasterid.cfd>buy propecia in uk</a> Presence of life threatening metastatic visceral disease, defined as extensive hepatic involvement, or any degree of brain or leptomeningeal involvement past or present, or symptomatic pulmonary lymphangitic spread

    on February 19 2024, 10:03

  • #49 loe2

    +1

    on February 21 2024, 10:58

  • #50 Knoccax

    doi 1177 2055102919838907 <a href=https://levitr.sbs>levitra cheapest price</a> From Phish s show at The Garden April 22, 2022

    on February 21 2024, 17:46

  • #51 tpLYLBu

    <a href=https://tadalafi.cfd>canadian pharmacy cialis 20mg</a> Tamoxifen is effective in the prevention and treatment of breast cancer, but its use is associated with an increased risk of thrombosis

    on February 22 2024, 8:21

  • #52 QDqjepohc

    <a href=https://tadalafil.top>cialis 10mg</a> You ve been feeling down lately, lethargic, even depressed

    on February 23 2024, 5:09

  • #53 JczLBFUh

    Electrophysiological measurements performed in wedges are expressed as mean SEM <a href=http://cials.cfd>cialis pills</a> I have now been at the club for 17 years and I still really enjoy playing, especially the camaraderie

    on February 24 2024, 6:15

  • #54 Seaf

    which insures Tyler Medical Clinic, said that the generous settlement will not affect the company s underwriting policy <a href=https://bcialis.mom>cialis from india</a> tolmetin, ketorolac intranasal

    on February 26 2024, 10:12

  • #55 Dier

    Galen, USA 2022 06 27 15 28 07 <a href=https://dapoxetin.buzz>priligy equivalent</a> Witte CL, Witte MH, Dumont AE, Frist J, Cole WR Lymph protein in hepatic cirrhosis and experimental hepatic and portal venous hypertension

    on February 28 2024, 8:08

  • #56 Agicecype

    <a href=https://sildenafi.sbs>does viagra work on paralyzed man</a> Thank you for taking time to write this

    on February 29 2024, 9:00

  • #57 Dier

    <a href=https://cial.sbs>brand name cialis online</a> 6 and 26 times the MRHD see Data

    on February 29 2024, 20:56

  • #58 Seaf

    In situ hybridization studies of prostacyclin receptor mRNA expression in various mouse organs <a href=http://dapoxetin.buzz>can priligy cure pe</a>

    on March 1 2024, 11:21

  • #59 Agicecype

    <a href=http://viagr.buzz>buy viagra cvs</a> 25mg Gengraf, Neoral, Sandimmune 50mg Gengraf, Sandimmune 100mg Gengraf, Neoral, Sandimmune

    on March 1 2024, 18:38

  • #60 DURNEKERE

    TCfeline SPECIAL FORMULA <a href=https://sildenafi.cfd>how does viagra affect women</a> And they contribute mostly to Republicans

    on March 2 2024, 7:00

  • #61 Knoccax

    Ullrich KJ, Rumrich G <a href=http://levitr.cfd>prix levitra pas cher</a>

    on March 3 2024, 23:05

  • #62 DURNEKERE

    Microsomal proteins isolated from the liver and intestine were quantitated using the Bradford protein assay 22 <a href=https://viagrax.lol>viagra results</a>

    on March 4 2024, 12:23

  • #63 Dier

    <a href=https://viagr.buzz>does cvs sell viagra</a> In sections II

    on March 4 2024, 23:26

  • #64 Dier

    What can be used to used to treat hot flashes <a href=https://cialiss.hair>cialis from usa pharmacy</a>

    on March 5 2024, 16:09

  • #65 Dier

    5 yr Brussels Griff, 9 lbs dx started seeing blood mucous in stool, lethargy, hair loss, skin warts, black discoloration son skin <a href=http://cialiss.hair>cialis without a doctor's prescription</a> Brunell PA, Gershon AA, Hughes WT, Riley HD Jr, Smith J 1972 Prevention of varicella in high risk children a collaborative study

    on March 6 2024, 10:04

  • #66 Hans

    Please let me know if you're looking for a article writer for your
    blog. You have some really good articles and I believe
    I would be a good asset. If you ever want to take some of the load off, I'd
    really like to write some material for your blog in exchange for a link back to mine.
    Please shoot me an email if interested. Thanks! dark web marketplaces https://mydarkmarket.com

    on March 6 2024, 16:40

  • #67 paurrylep

    <a href=http://sildenafi.sbs>chinese herbal viagra pills</a> 22, 23 Neutrophil recruitment to the intestine is thought to be coordinated by IL 8, and the polymorphism in the IL 8 promoter is thought to influence the manner in which neutrophils are recruited to the intestines when CDI is present

    on March 18 2024, 22:15

  • #68 Mike

    Das ist jetzt ein Test

    on March 20 2024, 6:42

  • #69 Mike

    Das ist jetzt ein Test

    on March 20 2024, 6:43

  • #70 BaroCrott

    <a href=http://acialis.sbs>buy cialis online using paypal</a> Lower Bp Without Medication

    on March 21 2024, 8:41

  • #71 Randell

    I do agree with all the ideas you have offered in your post.
    They're very convincing and will definitely work. Nonetheless, the posts are very quick for
    beginners. May you please lengthen them a little from subsequent time?
    Thank you for the post. dark market https://mydarknetmarketsonline.com

    on March 22 2024, 2:56

  • #72 BaroCrott

    <a href=http://sildenafi.buzz>lemon juice and olive oil viagra</a> announced that it would close its North American manufacturing plants, laying off almost 2, 000 workers

    on March 23 2024, 18:11

  • #73 paurrylep

    <a href=http://acialis.sbs>buying generic cialis online safe</a> Appropriate amount of Lipofectamine 3000 reagent was diluted in the Opti MEM I medium cat 31985, Thermo Fisher Scientific without serum

    on March 24 2024, 16:25

  • #74 BaroCrott

    <a href=https://ciali.top>cialis pills for sale</a> Cummings JL, Lyketsos CG, Peskind ER, et al

    on March 28 2024, 14:40

  Retour aux projets

Projets similaires