× Any questions about Documents Sellers, post it here .

Sort Documents by Title

  • quartz
  • Topic Author
  • Offline
  • New Member
  • New Member
More
9 years 9 months ago #25692 by quartz
Sort Documents by Title was created by quartz
I would like to have the documents in a category sort by title in ascending order. I have changed the configuration tab to select "Title" as the default ordering, but documents still appear on the page in the order they were added.

How can I change the order, without renumbering everything in the database?

Note that I have red another post about sorting by date, but I do not have the file mentioned. In the models directory I have files doc,php, docs.php, doument.php and mydocs.php.

Please Log in or Create an account to join the conversation.

More
9 years 9 months ago #25809 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Re: Sort Documents by Title
Hi

You can follow the instructions below to make it works :

1. Open the file components/com_dms/models/category.php

2. Find the code below :(line 146)
$orderby = ' ORDER BY a.ordering';

3. Change it to :
$orderby = ' ORDER BY a.title';

After that, it should work as expected.

Tuan
The following user(s) said Thank You: quartz

Please Log in or Create an account to join the conversation.

  • quartz
  • Topic Author
  • Offline
  • New Member
  • New Member
More
9 years 6 months ago #30313 by quartz
Replied by quartz on topic Re: Sort Documents by Title
Changing the category file as suggested worked for existing documents, but I have added a few more, and they are showing in order of upload, not by title.

So my list is very messy. How can I fix it?

Please Log in or Create an account to join the conversation.

More
9 years 6 months ago #30359 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Re: Sort Documents by Title
Strange. That changes should work for all documents, not only existing documents. Could you please submit a support ticket sending us administrator and FTP account of your site so that we can check and solve it for you ?

Regards,

Ossolution Team

Please Log in or Create an account to join the conversation.