htmly icon indicating copy to clipboard operation
htmly copied to clipboard

Allow normal commenting other than FB/Disqus

Open vdbhb59 opened this issue 2 years ago • 23 comments

Hi Team,

Though I did try to find if anything was already discussed or requested on this one, and since I could not locate here goes the request: Allow non-api based commenting, like guest comments, and allowing email address as optional, but name to be mandatory. Along with the email one, you can allow linkedin and xmpp. Example: Name - Mandatory (only alphabets with space and dot allowed) e-Mail - M/O (depends on HTMLy developers. though if mandatory, then temp-mail id's not allowed, as they turn into spamming a lot). However, my opinion would be to make email mandatory to avoid spamming. Comments/Remarks: Normal how it should be. Add/reply: Normal Like/Flag: For moderation purposes.

Not everyone has FB or Disqus and would be awesome to have comments on my blogs section. I am not a coder myself, so can only suggest here.

vdbhb59 avatar Jul 28 '22 14:07 vdbhb59

There are several commenting system on PHP that use flat files and can be integrated easily with HTMLy. Once I used Flatboard on my HTMLy blog. Flatboard makes it possible for one to comment without having to authenticate. It's quite nice: https://flatboard.org

Now I prefer to use a very basic commenting system. You can see it at the end of the page: https://padiracinnovation.org/News/2021/07/reduced-incidence-of-dementia-after-vaccination-against-chickenpox-and-shingles

Hjertesvikt avatar Jul 28 '22 14:07 Hjertesvikt

@Hjertesvikt is that your HTMLy blog with some flatboard theme or commenting setup? Apologies, as I mentioned, I am not a developer and have limited knowledge, but would love to have a commenting system without having to have the code knowledge.

Edit: Anyways, I recall now. Flatboard basically does not allow to modify certain things without going pro, and I recall now, it is buggy for me for my materials anyways.

vdbhb59 avatar Jul 28 '22 14:07 vdbhb59

Sorry I do not have the code anymore, but what you need to do is "just" put the code for Flatboard in some subfolder and add one or two lines of code in your theme. Indeed this is a kludge that would stop working next time you update the theme.

I don't remember Flatboard having bugs, but I did not test recent versions.

Hjertesvikt avatar Jul 28 '22 14:07 Hjertesvikt

Does your site still run that same flatboard you installed and setupped? If so, can you not go to your panel and share that commenting stuff if possible? Just asking, if that is possible, else no worries. :) I presume, it is POST code that you have with box-set, and though I am studying HTML myself, I am at the nasal stage and would be better having the team here do it to keep it proper. :) Anyways, even if you do help me, this option to HTMLy would be better within its own code, rather than having to add something off 3rd party.

vdbhb59 avatar Jul 28 '22 15:07 vdbhb59

I do not use Flatboard anymore, but really the integration in HTMLy was simple. Basically it was a matter to add/change a few lines in your theme. Something like that in layout.html.php:

			<!-- Forum  section 
                            <aside class="archive aside section">
                                <div class="section-inner">
                                    <h2 class="heading">To learn more</h2>
                                    <a href="/News/model/comments/index.php">Ask your questions here</a>
                                </div>
                            </aside>
                    <!--//section-->

Hjertesvikt avatar Jul 28 '22 15:07 Hjertesvikt

So something like this should work, right?

<!DOCTYPE html>
<title>My Example</title>

<form action="/html/tags/html_form_tag_action.cfm" method="post">
<div>
<textarea name="comments" id="comments" style="font-family:sans-serif;font-size:1.2em;">
EXAMPLE TEXT HERE,....
</textarea>
</div>
<input type="submit" value="Submit">
</form>

vdbhb59 avatar Jul 28 '22 15:07 vdbhb59

Sorry I do not have much time now. Here is the code I used. Put the "comment" folder somewhere and change the code in layout.html.php to point to that folder. I found it here: https://urgero.org

Hjertesvikt avatar Jul 28 '22 16:07 Hjertesvikt

Sorry I do not have much time now. Here is the code I used. Put the "comment" folder somewhere and change the code in layout.html.php to point to that folder. I found it here: https://urgero.org

Thanks, but I believe you forgot to give the code?

vdbhb59 avatar Jul 28 '22 17:07 vdbhb59

comments.zip Sorry for the delay

Hjertesvikt avatar Jul 28 '22 19:07 Hjertesvikt

I did try this, but as I mentioned, having literally no coding knowledge, I think I am doing something wrong here, and am unable to know what to add and what line in the layout file. Apologies, if I sound stupid, but...

vdbhb59 avatar Aug 03 '22 06:08 vdbhb59

Having a problem that no matter what I try I can't register anyone including the admin. I'm testing this on a localhost and maybe that is the problem. How have you set the users and thread folders?

afoster1955 avatar Aug 03 '22 18:08 afoster1955

Having a problem that no matter what I try I can't register anyone including the admin. I'm testing this on a localhost and maybe that is the problem. How have you set the users and thread folders?

I only have an admin account. I do not have idea of how to add a new user. Though I am doing it on a server side, and not localhost.

vdbhb59 avatar Aug 05 '22 09:08 vdbhb59

I was able to register the admin on the localhost so that part is done. Do you know which file in htmly this should be connected to so that the comment module is visible to the reader? Once I turn off the disqus option, I can't get any comment system to work with htmly

afoster1955 avatar Aug 05 '22 11:08 afoster1955

I was able to register the admin on the localhost so that part is done. Do you know which file in htmly this should be connected to so that the comment module is visible to the reader? Once I turn off the disqus option, I can't get any comment system to work with htmly

@Hjertesvikt commented this: Put the "comment" folder somewhere and change the code in layout.html.php to point to that folder. I presume that is how it should work. I am not even aware how to point, as I have literally no knowledge of coding. If you get it sorted, do let me know too pls.

vdbhb59 avatar Aug 05 '22 14:08 vdbhb59

My localhost is running php version 7.4.xx and evidently the comment system files are not at that level so I am getting errors that basically says they are not compatible. I guess I will try to get Disqus working. BTW, it won't work at all using layout.html.php...I tried using post.html.php instead.

afoster1955 avatar Aug 05 '22 16:08 afoster1955

My localhost is running php version 7.4.xx and evidently the comment system files are not at that level so I am getting errors that basically says they are not compatible. I guess I will try to get Disqus working. BTW, it won't work at all using layout.html.php...I tried using post.html.php instead.

Ohh, from the name it sounds, it should work. If you can get it working, do let me know. It is not something urgent, but it would be great to have a normal commenting system without having to go through any 3rd party ones.

vdbhb59 avatar Aug 06 '22 06:08 vdbhb59

I have come across a comment system that is pretty simple but I think it would work with HTMLy. The problem I am having is setting up the correct page_id so that the comment will apply to the article being written about.

An article's url is set up like this: domain/blog_folder/post/title-of-article I can put in the current_url as domain/blog_folder/post/ but how do I identify the title of the article. Does anyone know?

afoster1955 avatar Aug 08 '22 15:08 afoster1955

In the comment system I sent, it's done like this (post.php)

    ```
<input style="display: none;" name="post-id" id="post-id" value="';
    echo $_GET['post'];
    echo '"></input>
Which is rendered like this:


<h3>Thread comments</h3><h4>Write the first post!</h4><form action="https://padiracinnovation.org/News/model/comments/submit.php" method="POST">
--
  | <input style="display: none;" name="type" id="type" value="reply"></input>
  | <input style="display: none;" name="post-id" id="post-id" value="plasma-biomarkers-of-inflammation-and-vascular-injury-are-associated-with-cognitive-decline."></input>
  | <textarea name="text" id="text" rows="10" cols="50%"  cols="50" class="form-control"></textarea><br />
  | <button type="submit" class="btn btn-primary pull-right">Submit</button>
  | </form>

Hjertesvikt avatar Aug 08 '22 18:08 Hjertesvikt

You can see an example there: https://padiracinnovation.org/News/2022/08/ggg

Hjertesvikt avatar Aug 08 '22 18:08 Hjertesvikt

Yes, this is now working as is.

Can this be adapted to work with a separate blog without having to login to leave a comment?

afoster1955 avatar Aug 08 '22 21:08 afoster1955

I was finally able to get Commentics to work with HTMLy. https://www.commentics.com

afoster1955 avatar Aug 10 '22 17:08 afoster1955

I looked around for a comment program before. Looks like commentics requires a db. I'm not a DB fan which explains why I'm here. I may give it a try though thank you for sharing.

AutomationMan808 avatar Aug 11 '22 23:08 AutomationMan808

I tried other comment systems and could never get any of them to work. Commentics worked after just a little bit of tweaking.

afoster1955 avatar Aug 12 '22 14:08 afoster1955