Sorting related articles
- Posted by Felix Aretz (4) Offline
Hi, is it possible to add an option: Order: Recently created last?
I use Joomla articles to "simulate" a calendar for motorsport events. The blog-view is ordered by created date which works well to show the next upcoming event first (see attachment).
The related articles module is used to show other articles for the selected location. But the order is in the opposite direction.
Please help
8 years 2 months ago #1
by Felix Aretz
I use Joomla articles to "simulate" a calendar for motorsport events. The blog-view is ordered by created date which works well to show the next upcoming event first (see attachment).
The related articles module is used to show other articles for the selected location. But the order is in the opposite direction.
Please help

Please Log in or Create an account to join the conversation.
- Posted by TemplatePlazza (5310) Offline
Hi, I haven't tested it but you can try this :
Please open this file : ../modules/mod_relateditems_xtd/helper.php at lines 318 - 324 you will see this :try to change it to :
8 years 2 months ago #2
by TemplatePlazza
Please open this file : ../modules/mod_relateditems_xtd/helper.php at lines 318 - 324 you will see this :
//ordering option
switch($ordering) {
case 0: default: $orderby = "a.created DESC" ; break;
case 1: $orderby = "a.hits DESC"; break;
case 2: $orderby = "a.ordering DESC"; break;
case 3: $orderby = "RAND()"; break;
}
//ordering option
switch($ordering) {
case 0: default: $orderby = "a.created ASC" ; break;
case 1: $orderby = "a.hits DESC"; break;
case 2: $orderby = "a.ordering DESC"; break;
case 3: $orderby = "RAND()"; break;
}
Please Log in or Create an account to join the conversation.
- Posted by Felix Aretz (4) Offline
Thanks for the quick response but unfortunately it doesn't help.
8 years 2 months ago #3
by Felix Aretz
Please Log in or Create an account to join the conversation.
- Posted by TemplatePlazza (5310) Offline
Hi, are you sure? the code purpose is about to change the direction. Could you let me know the URL of your site so I can take a look?
8 years 2 months ago #4
by TemplatePlazza
Please Log in or Create an account to join the conversation.
- Posted by Felix Aretz (4) Offline
I found it. The same code appears at line 169 - 175. I changed it there and now it works.
One last question, how can I hide the caption "More articles"? I don't find any option for it.
8 years 2 months ago #5
by Felix Aretz
One last question, how can I hide the caption "More articles"? I don't find any option for it.
Please Log in or Create an account to join the conversation.
- Posted by TemplatePlazza (5310) Offline
Hi, sorry but do you use Related Item Extended module or something else? Because Related Item Extended doesn't have that "More articles" wording
8 years 2 months ago #6
by TemplatePlazza
Please Log in or Create an account to join the conversation.