Page 1 of 1
Any chance of an 'A' 'B' 'C' listing for news module
Posted: Mon Jul 05, 2010 3:31 pm
by buzzby
i am not sure if this exists already. i would like to know if there is a module that deals with listings in a alphabetical manor. i know that the news module already can list all articles by their starting letter.
etc
is there a way that a comprehensive list can be displayed by category? so all categories will be listed with their subjects in alphabetical order?
ART
- AS Level - Art History
A2 Level - Art & History
Btec 1st Art & Design Diploma
Btec Nat Art & Design Certificate
Also a little like the glossary can there be letter splits so that all courses under D or E can be clicked on to be viewed.
cheers
Re: Any chance of an 'A' 'B' 'C' listing for news module
Posted: Mon Jul 05, 2010 4:56 pm
by reneh
See help of news...
News have catagories.
For pagination by chars you must do some nice templating for list view...
Re: Any chance of an 'A' 'B' 'C' listing for news module
Posted: Mon Jul 05, 2010 10:45 pm
by beattie
If I've understood you correctly, I solved this problem not long ago with the help of a posting on this forum.
Open file action.browsecat.php (should be in folder modules/News)
Around line 31 replace this line:
$query .= ' ORDER by hierarchy';
With this line:
$query .= ' ORDER by long_name';
To show the list of categories in their alphabetical order put this in your page or page template:
{news browsecat="1" category="Articles*" sortby="news_title"}
Check News module help for other parameters. Articles is the parent name of the category, the asterisk * shows all the child categories (sub-categories).
See this page for a live example of a category list in alphabetical order:
http://www.kidsinmadrid.com/en/kim-business-directory.html
Re: Any chance of an 'A' 'B' 'C' listing for news module
Posted: Tue Jul 06, 2010 2:18 am
by Ted
SOSchildcare.com wrote:
Open file action.browsecat.php (should be in folder modules/News)
Around line 31 replace this line:
This isn't a valid solution anymore. News has been significantly changed, and it should be possible to do this without any code hacking. Using browsecat, properly setup category hierarchy and a little smarty magic, it should be pretty easy to do.
Good luck.