Forums

Unfortunately no one can be told what FluxBB is - you have to see it for yourself.

You are not logged in.

#1 2014-04-28 11:58:25

Whoracle
New member
Registered: 2014-04-28
Posts: 4

Closed Topic search

Disclaimer: Allrighty, I've searched for about 3 hours now, both here and via Google, but it may still be that I overlooked something. If that's the case, kindly point me towards existing topics or other resources.

The System: FluxBB 1.5.6 on Arch Linux with MariaDB and NGinx.

Digest: As far as I can tell there's no way to search explicitly for locked/closed topics in FluxBB 1.5.6.

The Problem: I'm hosting a small instance of FluxBB 1.5.6 purely for internal discussion, with no public/outside users. We tend to close topics pretty rapidly, as soon as each point is handled. Now I want to move those topics to a "graveyard" or "archive" category every once in a while. I guess I could make a database script that does this automagically, but then it'd be only me that can do this stuff, and I hate messing around with the databases of products I'm using unless I really understand how they work.

The Request: Make it so that I can search for "Closed:" in the search entry or something like that, so I can batch move (for example) closed topics that are older than X months.

As I said earlier, if there's already a way to do this, disregard my ramblings and kindly point me towards what I'm missing.

Thanks in advance smile

Offline

#2 2014-04-28 12:02:28

Franz
Lead developer
From: Germany
Registered: 2008-05-13
Posts: 6,047
Website

Re: Closed Topic search

Welcome! smile

This is currently not possible, you will have to create or install a modification (or better a plugin).

Because I kinda like the idea, I created a ticket, so you might see this in v2.0.

Anything else you like or dislike about FluxBB? Any feedback is welcome.


fluxbb.de | develoPHP

"As code is more often read than written it's really important to write clean code."

Offline

#3 2014-04-28 12:10:39

Whoracle
New member
Registered: 2014-04-28
Posts: 4

Re: Closed Topic search

Thanks for the Welcome and the fast reply smile

I'm glad that I wasn't too stupid to find the solution, then. Will track the ticket and either do it by hand or script until then.
I doubt I'll find the time to write a full-fledged, usable mod for this, but who knows? Miracles may happen smile

As far as feedback goes, I'm afraid I don't have too much. I like FluxBB exactly for what it does: No nonsense and lightweight Forums.
So far the only thing I'm kinda missing is subforums, for the exact same reasons outlined above:
Currently I plan on moving closed topics to a "mirror" of our regular forum structure into the respective archive forums. If I had subforums, I'd ditch the category and just have one subforum per forum with the archived threads in it.
But there's already enough people who are clamoring for subforums, so I'll just wait and see.
Apart from that "Human readable URLs" is the only thing I'm missing, and that's just a luxury request and can be done via Mods, so I'm fine smile

Can't wait to see what 2.0 brings.

Offline

#4 2014-04-28 12:25:19

Franz
Lead developer
From: Germany
Registered: 2008-05-13
Posts: 6,047
Website

Re: Closed Topic search

Thanks for the feedback!

Pretty URLs will be in v2.0, subforums too.


fluxbb.de | develoPHP

"As code is more often read than written it's really important to write clean code."

Offline

#5 2014-04-28 12:35:51

Whoracle
New member
Registered: 2014-04-28
Posts: 4

Re: Closed Topic search

Dirty way to do this:

Run the following query:
Assuming all your tables have the prefix flux_ (e.g. flux_topics, flux_forums, etc. and are in a database called fluxbb).
- Log into mysql
- Get your graveyard topic_id:

SELECT id, subject FROM fluxbb.flux_forums;

Let's say your graveyard topic_id is 13.

- Run the following query whenever you want to clean up:

UPDATE fluxbb.flux_topics SET forum_id = 13 WHERE closed = 1;

As soon as I find out how the timestamps are encoded, I'll adjust it so you can move only $AGEd closed topics. Once I get the timestamps sorted, I guess you could run this as a cronjob to keep everything clean. You can ostensibly expand this into a wildly mutated version where you either duplicate your whole category/forums tree under the graveyard again, or even pump all this into a duplicate database that only hosts your archives.

Note that this is almost completely untested! I tested it on my small instance and it works, although the cache won't get updated. Use at your own risk and try it out on a testdb first, and remember to make backups!

Further Notice: This is a REALLY raw and dirty workaround. It won't display the amount of topics in your graveyard on the index page, EVER. I made a new post about it in Modifications that I'll link here, because at this point it's no longer a feature request. I hope Modifications is the right place.

Since I can't yet post links, look in the 1.4/1.5 Modifications forum for a Thread called "Move closed topics to graveyard forum - database cleanup script".
Regards

Last edited by Whoracle (2014-04-28 16:02:47)

Offline

Board footer

Powered by FluxBB 1.5.8