Sphene Community Tools

Community

Copyright © 2007-2018 by Herbert Poul

You are not logged in.
Login
Register

Change Language:



AddThis Social Bookmark Button

A Django site.

Powered by Sphene Community Tools
Board » General » Feature Discussions » Category Icons for sphboard

being able to select an icon for a category (read/unread) seems for me a good extension of the board.
phpbb (with some settings) allows users to select the icon of their post, also posting threads and categories might have different icons, and so on.

having a function which returns the icons would be a good idea. so people can implement forums, which use user selectable icons (therefore more database stuff), while others only select certain icons for their own use generally, or by category, or even not at all (which means, it always returns a fixed string)

locally I can of course override sphenes default behaviour, but I think this would be a nice addon if supported by core (and some people respond to such "small things").
weltenfall.net
shouldn't be too hard to implement .. and sounds good..

do you mean that those are icons for the categories, or for threads within the category ? or both ?
do you know how other boards do this ? because i imagine if you have dozends of forum categories and want to change all icons it's quite some work if you have to click through all of them
Hey, we have Signatures !!! Great, isn't it ? ;)
normally, forums allow one icon (based on the theme) for a category, like a folder, and use a standard icon for threads (normally a sheet of paper). phpbb allows to enable the usage of a custom icon for the thread (which holds posts) by the writer of the thread. however that has to be enabled.

in phpbb there are icons for:
* category
* category with new posts
* thread (read)
* thread (new posts or new)
* thread (read, but i have posted there)
* thread (new posts, and i have posted there)
(all of these also in the form "hot topic")
* thread (locked)

since i would not hardcode that too much, create functions for it, which return the name of the icon based on given variables (category or thread? new? did i post in it? hot topic? locked?) and let the category class define the result itself. maybe a **kwargs function for being upwards compatible.

if somebody really wants to implement custom icons for everything, he can write a custom category, which has the ability to save that in the database.
per default i would return a fixed string for "category", "category_new", "thread" and "thread_new" icons, being relative icons from MEDIA_URL.
weltenfall.net
def get_thread_icon( self, is_category = True, is_new = True, is_hot = False, is_locked = False, **kwargs):
if is_category:
if is_new:
return "icons/folder_new.gif"
else:
return "icons/folder.gif"
elif is_new:
return "icons/thread_new.gif"
return "thread.gif"

as standard e.g.. to show my thoughts. for me that seems that everybody can create an own class and extend it to his needs. but you're the expert ;)
weltenfall.net

Please login to post a reply.



Powered by Sphene Community Tools