Search in support tickets

#909 – Sort by alphabetic and wrong site problem...

Posted in ‘Support’
This is a public ticket. Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.
Monday, 08 February 2021 19:47 CET
Hi, we have the next issues...

We want to see all Ads in an alphabetic Order on the Frontend. i can set the headline field for sorting but the sort field doesnt use it as default sort option, how can i fix it?

And the next problem: we use two links: the first is a normal link where u see the subcategories from one maincategory, the second link doesnt show the subcategories from this maincategory but all ads from them. the page title shows me the wrong title (the title from the first link) and when i want to use the sort option it goes to the first link and shows me the category...

i think joomla just see that both links have the same destination (index.php?option=com_adsmanager&view=list&catid=9&rootid=9)?!
Custom Fields
Joomla Version
PHP Version
Product Version
Tuesday, 09 February 2021 15:50 CET

1. To sort the ads by alphabetical order by default, you need to custom the code.
Open the file administrator/com_adsmanager/models/content.php and find the function getFilterOrder, then find the line 962 :
$filter_order = "a.date_created ".$orderdir." , ";

Change it like this by using the name of the headline field, in this exammple, I will use ad_headline
$filter_order = "a.ad_headline ASC , ";

2. I don't understand, could you give me a link to the page with the issue ?

Best regards.
Friday, 12 February 2021 07:13 CET
Thank you, the sorting is now working!

We probably already have a solution to the second question ...

We have two links in the front end. On the one hand, a normal listing of the first main category including all sub-categories and, on the other hand, a link that directly lists all ads. Since there are two links that practically each show the main category (one with sub-categories and one without), the front end always automatically pointed to the first link on the second link. For example, if I used the sorting in the second link, the link jumped and I ended up in the sub-category selection ...

I have now solved it so that the ads that should also be shown in the second link have been sorted into a further category and the second link only refers to this category.

I hope that was understandable. Either way the problem is solved!
Friday, 12 February 2021 08:27 CET

That's a great news :)

Don't hesitate to ask if you have other questions.

Best regards.

Please rate this ticket

Help us improve our support services by rating this ticket from one to five stars, according to how much you are satisfied from the handling of this ticket, one being not satisfied and five being very satisfied.