Display post categories for public viewing on a channel home page
Created by: anaqreon
How do I get the categories list to display on the channel home? I have categories enabled, but there is not the list of used categories on the left panel.
The categories widget is in the default channel pdl. Works for my channel. It may have something to do with wall-to-wall or tagged posts if you're not seeing them on a forum.
Hmm, I don't understand. I posted on the Hubzilla wall using my personal channel that I'm posting with now. Do you mean that categories might only display if they are on a post compose by the Hubzilla channel itself?
I'm saying it works for a normal channel posting to their own wall so if there is a bug on a non-normal channel and/or from another channel, this would be the first thing to check.
Just thinking ahead - categories don't "federate" so the only way they will possibly work on a forum is through a wall-to-wall and not through a remote mentioned post.
And having a quick look at the code - we always intended categories to be something private to the channel so our queries are based on the post author which is set explicitly to the channel owner. We aren't querying by post owner, only the author. This could take a bit of work and thinking through any potentially undesirable side effects to sort it out and it won't federate cleanly. I'm pretty busy if anybody else wants to to take a stab at it. I would probably recommend using tags instead of categories if you want topics for visitors to search with.
On the bright side I believe it is working in the hubzilla repo. On the cloudy side the query will possibly be too painful and slow to try and do this on a redmatrix DB. If you want to try it, it's in commit 070397ef and the only thing you need to change for red is
- and item.item_wall = 1 + and ( item.item_flags & " . intval(ITEM_WALL) . ") > 0
oh and change the last parameter of tagblock and wtagblock from 'wall' to ITEM_WALL iirc