Hello,
I am trying to show the top 5 most written about subjects in a page on my blog.
The subject field is a dropdown menu editable, and I can select which subject is linked to the article I'm creating.
What I did for now, is a table with all subjects, with the "k_total_records" data next to it. So I can see the information for each subjects.
I used that type of code for each subjects (nomsujet being the subject editable name, and 1031 being the value of a subject) :
I tried doing this :
I wanted to show change the order so that it goes by how many "total records" there is for each subjects, but I get that it cannot work since I'm not specifying any subjects, so it will show the total number of entries in the search.php page.
Any ideas how I can do this?
Thanks a lot!
I am trying to show the top 5 most written about subjects in a page on my blog.
The subject field is a dropdown menu editable, and I can select which subject is linked to the article I'm creating.
What I did for now, is a table with all subjects, with the "k_total_records" data next to it. So I can see the information for each subjects.
I used that type of code for each subjects (nomsujet being the subject editable name, and 1031 being the value of a subject) :
- Code: Select all
<cms:pages masterpage="search.php" limit="1" custom_field='nomsujet=1031'></td><td><cms:show k_total_records/></cms:pages>
I tried doing this :
- Code: Select all
<cms:pages masterpage="search.php" limit="5" orderby=k_total_records order="desc"><cms:show nomsujet/> = (<cms:show k_total_records/>)</cms:pages>
I wanted to show change the order so that it goes by how many "total records" there is for each subjects, but I get that it cannot work since I'm not specifying any subjects, so it will show the total number of entries in the search.php page.
Any ideas how I can do this?
Thanks a lot!