Jump to content

HermodBB - Basic BB/Forum/Comments module


Recommended Posts

  • 2 weeks later...

I also started with "discuss" a simple, extendable forum module based on PW pages few month ago, but stopped work in favor of Flarum (Demo). I like the EsoTalk successor and maybe start an integration for my small forum site instead of a native PW forum...

My stopped "discuss" module was as simple as possible. The base module was planned without an admin / moderator panel and it should just take care about add and edit (own) posts and a structured view (EsoTalk / Flarum like discussions, also with user based view permissions for private topics instead of private messages).

At the moment I haven't started an Flarum integration (no time and it's beta), but it could be interesting in the future.

HermodBB could be interesting, but strategic focus should be the frontend and usability (at the beginning PW backend would be fine to administer / moderate the boards and posts).

My key features

  • tag based structure instead of categories / page tree
  • private conversations by tagging topics with allowed users (or groups?)
  • ajax notifications (PW notifications module?) about new replies and changes in the actual view

All other stuff ("like" feature, backend, ...) should be added as optional extensions / plugins (PW hooks)

  • Like 1
Link to comment
Share on other sites

Hi all,

With December being a busy month for me, I'm not had time to work on this. I should have more free time during the New Year. I'll hopefully then be able to throw up some code (Github) for others to look at and tear apart etc, and a demo etc.

@pwFoo HBB will also be lightweight at the core, with just the needed features for a basic forum. As you say, plugins/modules etc could add other functionality if needed. I won't be adding features like tags, likes, notifications etc into the HBB core as PW can handle all of that in a variety of ways, and people may already have modules installed that could be utilised for that purpose. My plan is to make it all doable for the forum member from the frontend, i.e for them to be able to post and edit their content without ever seeing the admin area. How this is done via the frontend will be up to the developer of the site that HBB is installed on. This will allow people to use whatever frameworks/scripts they want for the frontend and then HBB can simply store the data when requested.

Well that's my big plan at least. A simple forum that can be extended in an unlimited amount of ways thanks to the power of PW. I love the fact that I can just add a new field to the user template, i.e for a profile picture and then this can easily be used for HBB if needed.

Anyway, I'll throw up some code soon enough, and then everyone can see whether or not I'm on the right track.

  • Like 2
Link to comment
Share on other sites

My approach works with a page "tags" (or categories... as you want, also sub categories are possible) and a page "topics". All children of tags are used to build the forum structure (page reference) and replies are saved as children pages of the topic page. So forum structure is  separated from the forum contents (topics and replies) which was important for me. And all contents (topics and also replies are just pages (do you use the comment module or also pages for replies?).

Link to comment
Share on other sites

  • 1 month later...

My approach works with a page "tags" (or categories... as you want, also sub categories are possible) and a page "topics". All children of tags are used to build the forum structure (page reference) and replies are saved as children pages of the topic page. So forum structure is  separated from the forum contents (topics and replies) which was important for me. And all contents (topics and also replies are just pages (do you use the comment module or also pages for replies?).

The idea is to have no dependencies, so a fresh install of PW would provide everything needed. Replies are stored as pages under a sub-page called "Comments". I've followed along the route of topics and comments so that comments (or replies) can also be used for other pages throughout a site.

This image explains it more:

Tree.jpg

The module installs all the required fields and templates expected for a basic forum, it's then up to the user in regards to the markup and how to sanitize the data etc. It doesn't really do much more than that, other than to obviously save the data through custom methods.

I have some code as stated previously, but I'm afraid people will laugh at it, as I know a lot of people on here could easily do a better job.

  • Like 3
Link to comment
Share on other sites

For me, this looks good. If this is a module and it creates all the required fields and templates and handles data / pages, what is missing?

This is a lot! ^-^

If you have the possibility to upload this into a GitHub repo, this would be a good start to test, if someone will laugh, :)

I don't think so. But maybe others start to use it and contribute a bit here and a piece there. Who knows?

  • Like 2
Link to comment
Share on other sites

For me, this looks good. If this is a module and it creates all the required fields and templates and handles data / pages, what is missing?

This is a lot! ^-^

If you have the possibility to upload this into a GitHub repo, this would be a good start to test, if someone will laugh, :)

I don't think so. But maybe others start to use it and contribute a bit here and a piece there. Who knows?

^-^

I will upload it to Github this week for people to try. I'm just cleaning up the coding errors I decided to implement while drunk over Xmas :-X  Also I'm not totally familiar with Github, but I should be able to get something useful up before the weekend.

  • Like 4
Link to comment
Share on other sites

Ok, after a quick crash course with Github, I managed to upload the module for testing. I've included my test templates which should give an idea of how to use the module. I use UIkit for testing, so that's the markup you'll find in the templates.

Obviously this is early code and has only been tested by me, so don't use it for anything other than testing. The module does NOT sanitize, so you need to ensure you have sanitized your message before you use the topicSave() or commentSave() methods. Documentation is nonexistent, but the module is fairly straight forward and I can help where needed.

So, thoughts, issues, insults? Does it have potential? and if anyone wants to add to it etc, please let me know.

Link removed - HermodBB is now discontinued and is now being developed as LiteBB. I will update the thread with further information.

  • Like 3
Link to comment
Share on other sites

  • 2 weeks later...

I was thinking about splitting this into two modules. One that's responsible for the forum setup and topics and another for the comments. The comments module would be a page-based comments module. This would then give the option to use either Ryan's Comments Fieldtype, or this page-based version with the main forum module for topic replies.

Edit: Since I released the source code, there's not been any feedback, so I assume my code is bad. For that reason, I'm going to commence with my above suggestion and split the module into two manageable pieces of code, starting with the comments module. This thread can now be deleted as I will no longer be releasing it as HermodBB.

  • Like 2
Link to comment
Share on other sites

  • 1 month later...

Since I released the source code, there's not been any feedback, so I assume my code is bad. For that reason, I'm going to commence with my above suggestion and split the module into two manageable pieces of code, starting with the comments module. This thread can now be deleted as I will no longer be releasing it as HermodBB.

Hey, steady on, tiger, let's give it a try.

I just installed the module on a fresh 2.7.2 install (Basic profile) and followed the instructions in the repo and everything installed beautifully. I also created rough root, forum and topic pages, just for testing.

The first thing puzzling me is that I also added a new PW role 'member', expecting to give that role 'create topic' and suchlike privileges, but, to me, the config options in the backend aren't coming up where I'd expect them (at subforum level), but at topic level. And there's no sign of my 'member' role being offered the chance to do anything. Is there something I have done wrong?

I would like to spend some time giving whatever help I can to help make this work.

  • Like 3
Link to comment
Share on other sites

Hey, steady on, tiger, let's give it a try.

I just installed the module on a fresh 2.7.2 install (Basic profile) and followed the instructions in the repo and everything installed beautifully. I also created rough root, forum and topic pages, just for testing.

The first thing puzzling me is that I also added a new PW role 'member', expecting to give that role 'create topic' and suchlike privileges, but, to me, the config options in the backend aren't coming up where I'd expect them (at subforum level), but at topic level. And there's no sign of my 'member' role being offered the chance to do anything. Is there something I have done wrong?

I would like to spend some time giving whatever help I can to help make this work.

Hi DaveP,

Firstly, it's worth noting that I have changed the module slightly, including the names of some fields etc, so this version will be incompatible. It will be released as LiteBB rather than HermodBB, hence the reason I requested for this thread to be deleted. However, thanks for your feedback. I would assume that your problem is related to the incorrect template being used for your sub-forum? What template is your sub-forum page using? It should be using HBB Forum (hbb_forum).

What I will do is release the code for updated version which is more or less the same, but doesn't include the code for the replies or comments as this will most likely be released as a separate module, or you can use Ryan's Comments module if preferred.

Link to comment
Share on other sites

  • 1 month later...

GuruMeditation,

I just came across your HermodBB and it looks great. Installation went as expected. I'm struggling with getting it in place but I'm a neophyte and still learning, so I expect those are issues on my side.

Curious about your most recent comment on releasing as LiteBB. Where does that stand?

Edit: bad typing corrected.

Edited by rlwsota
Link to comment
Share on other sites

GuruMeditation,

I just came across your HermodBB and it looks great. Installation went as expected. I'm struggling with getting it in place but I'm a neophyte and still learning, so I expect those are issues on my side.

Curious about your most recent comment on releasing as LiteBB. Where does that stand?

Hi rlwsota,

I have started to rewrite some code and it will be released as LiteBB. The test code module I released can be classed as discontinued at this stage, so I don't recommend using it. The code for LiteBB is similar but I have renamed some fields etc and have started to rethink some aspects.

At the moment I'm thinking along the following lines:

  • LiteBB module (the core), which will essentially install the required templates and fields that you would expect for a forum. Just like HermodBB does now.
  • Page-based Comments module. Comments are topic replies, and I'd like to offer a page-based version of Ryan's. My idea being that LiteBB users can choose to use their preferred module for the comments.
  • Various optional modules. An example being the Lumberjack logger module I released that is responsible for logging the user's IP / User Agent etc.
  • Like 1
Link to comment
Share on other sites

GuruMeditation,

Thanks for the reply and update on your LiteBB efforts. Sounds promising and I like the ability to tie your Lumberjack logger in easily.

I will heed your recommendation on HermodBB and not work with it any longer.

Do you have ETA for LiteBB to make its debut?

Link to comment
Share on other sites

Do you have ETA for LiteBB to make its debut?

Basically as soon as I can. This is something that I would love to use myself, so I am eager to get it finished for various personal projects. I could have finished this by now if it was for my personal use, as I would have cut corners here and there, but I want to release it as a module that everyone can use. This is a part time project for me as I'm not a PHP programmer, so I often don't know what I'm doing. But I have the ideas and a vision, so I will crack on and hope others comment on my code in order to improve it.

As a prime example, do you personally like the idea of being able to choose your own module for the comments / replies? I could hard code it into the core module as I did previously with HermodBB, but if other modules exist to fit the bill, then why invent the wheel? But that's just my opinion.

PW gives us so much flexibility, and that's what I want to take advantage of. PW takes care of users, permissions, profiles, and that's the beauty of it as it's something I don't need to bother with.

  • Like 2
Link to comment
Share on other sites

Understood. I applaud your efforts (and those of all who create modules for PW) for the diligence required. Perhaps as my neophyte-ness fades, I'll be able to contribute something of value.

As for your question, I'm always keen on options but agree that there is little need to reinvent the wheel. If a current solution doesn't fit the need, that's a good reason to revisit the matter but for most uses that's probably not the case.

PW is great for lots of reasons, including its inherent flexibility.

Link to comment
Share on other sites

  • 2 years later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...