Comments (10)
thank you for the information
from htmly.
Thank you for your help.
from htmly.
Hello,
You just need to remove this one <?php session_start(); ?>
because we already called it.
from htmly.
Hello,
When I remove when <?php session_start(); ?>
When there is a new comment, it is not visible on the new device.
When cleared from here, a comment is displayed
/admin/clear-cache
from htmly.
For users who are not logged in, each visit will be given a cache page if the cache feature enabled. So if you are using PHP integration (the comments included directly to the page) with cache enable, ideally you need to delete the post cache every time new comment added and this requires a custom code.
The simplest way, of course, uses iframes like in their WordPress plugins.
from htmly.
Hello,
From here I need to take the code and link to the cache.
But I don't understand where the file is located.
Link:
https://commentics.com/events
<?php
/* Event for when a new comment is added */
if ($event == 'comment_added') {
// add your own code here
}
from htmly.
The cache is in cache/page folder.
Try in post.html.php
<?php
$cmtx_identifier = strtok($_SERVER["REQUEST_URI"],'?');
$cmtx_reference = $p->title;
$cmtx_folder = '/comments/';
require($_SERVER['DOCUMENT_ROOT'] . $cmtx_folder . 'frontend/index.php');
?>
And all.php
example:
<?php
/* Event for when a new comment is added */
if ($event == 'comment_added') {
$c = str_replace('/', '#', rawurldecode($page_identifier));
$cachefile = dirname(CMTX_DIR_ROOT) . '/cache/page/' . $c . '.cache';
if (file_exists($cachefile)) {
unlink($cachefile);
}
}
from htmly.
Hello
i can't figure out where i should create the folder all.php
from htmly.
Well already written here: https://commentics.com/events
To listen for an event, create a file called all.php inside the folder below:
/comments/system/events/
from htmly.
Added the code to the docs.
from htmly.
Related Issues (20)
- [FEATURE REQUEST] Plz add version number on footer HOT 6
- [FEATURE REQUEST] Admin to User Problem HOT 1
- [QUESTION] Theme Issue HOT 1
- [QUESTION] Sitemap.xml - is listing only my current year OR max 39 rows HOT 3
- Errror On Installation HOT 2
- Ukrainian language HOT 1
- Subscribe Module HOT 3
- Hello, there is some error on the sitemap HOT 6
- [FEATURE REQUEST] Menu editor, supports relative URL HOT 1
- May be we should not put tags in the markdown file title HOT 1
- [BUG REPORT] Attribute charset not allowed on element meta at this point. HOT 1
- [FEATURE REQUEST]How to integrate into root domain? HOT 2
- [QA] page break (pagination), blogroll not on home page, multimedia dir tree, relative urls etc. HOT 9
- Link previews not reflecting the real logos or the favicon - HTMLY/Ignite HOT 3
- Supporting Arabic commas under "tags"[FEATURE REQUEST] HOT 2
- draft posts pooled after common publish article click HOT 5
- [FEATURE REQUEST] STATUS heading/column in posts list HOT 1
- [FEATURE REQUEST] QOL features: splitting lang, visits counter HOT 5
- [QA] How can we list the blog (latest blog snippets) on the homepage which is outside the htmly folder? HOT 1
- Sub sub menu ? HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from htmly.