It is currently Tue Oct 24, 2017 1:17 pm

All times are UTC + 1 hour [ DST ]




Post new topic Reply to topic  [ 5 posts ] 
Author Message
PostPosted: Sat Apr 12, 2014 11:01 am 
Offline

Joined: Sat Apr 12, 2014 10:55 am
Posts: 3
Hi, how i can change sorting directories and photo images by name? Default sorting (arrange) is bad for me because first item is 1,2,3,4,5,6,7,8,9 (i want sorting reverse --- 9,8,7,6,5,4,3,2,1). I need sorting items with name: year-month-day-somethink and first item must be the youngest.

Very much for any idea.

.........Reverse order joomla 2.5 admiror gallery 4.5


Top
 Profile  
 
 Post subject: Reverse order joomla 2.5 admiror gallery 4.5
PostPosted: Sat Apr 12, 2014 11:01 am 
Top  
PostPosted: Tue Apr 22, 2014 6:51 pm 
Offline
Developer
Developer
User avatar

Joined: Sat Aug 14, 2010 9:31 pm
Posts: 1241
Location: Novi Sad, Serbia
You can change the way the list is ordered in agHelper.php, function:
Code:
 public static function array_sorting($array,$targetFolder,$arrange) {

Change : return $array; to
Code:
return array_reverse($array)

_________________
Help Admiror Gallery become even better,
give us a review on JED


Top
 Profile  
 
PostPosted: Tue Apr 22, 2014 6:58 pm 
Offline

Joined: Sat Apr 12, 2014 10:55 am
Posts: 3
Thank you for your answer, i try it.


Top
 Profile  
 
PostPosted: Sat Jul 05, 2014 7:27 pm 
Offline

Joined: Mon Jun 03, 2013 9:29 am
Posts: 8
Vasiljevski wrote:
You can change the way the list is ordered in agHelper.php, function:
Code:
 public static function array_sorting($array,$targetFolder,$arrange) {

Change : return $array; to
Code:
return array_reverse($array)


Hello... I have the same situation... I need change the order of albums names... default is ascending... i need descendigng...
i find this code in agHelper.php... but i do not understand what i must insert or replace...
can you explain? thank you very much!


Top
 Profile  
 
PostPosted: Sun Aug 17, 2014 2:27 am 
Offline
Developer
Developer
User avatar

Joined: Sat Aug 14, 2010 9:31 pm
Posts: 1241
Location: Novi Sad, Serbia
Well I'm not sure what is the default ordering, but anyway you just need to sort the image array the way you need before the gallery is rendered.

In your case, you could set ordering by name in the settings, and just apply the reverse order like explained above. This way you will get opposite ordering, in you case descending.

_________________
Help Admiror Gallery become even better,
give us a review on JED


Top
 Profile  
 
 Post subject: Re: Reverse order joomla 2.5 admiror gallery 4.5
PostPosted: Sun Aug 17, 2014 2:27 am 
Top  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 5 posts ] 

 


All times are UTC + 1 hour [ DST ]


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron

This is the official Admiror Joomla! Community Forum. You are welcome to join the Admiror Joomla! Community. All Admiror Joomla! Extensions Users, Joomla! Developers, PHP or mySQL Developers are welcome to support & contribute to Admiror Joomla! Projects.

Joomla! is a free and open source content management system (CMS) for publishing content on the World Wide Web and intranets. With a vibrant volunteer community, user-friendly features and plenty of power, Joomla is perfect for your website!

Joomla! is written in PHP, uses object-oriented programming (OOP) techniques and software patterns, stores data in a MySQL database, and includes features such as page caching, RSS feeds, printable versions of pages, news flashes, blogs, polls, search, and support for language internationalization.

Joomla! is the property of Open Source Matters, Inc. All rights reserved. Read more about Joomla! at http://www.joomla.org/.


Protected by Anti-Spam ACP Powered by phpBB® Forum Software © phpBB Group