Eazyest Gallery
Eazyest_FolderBase::get_folder_images() (1 post)

  1. n0ll
    Posted 1 year ago #

    I recently put up a test installation of my blog at photo.mjsb.eu, using eazyest-gallery. After some configuration issues and fixing directory permissions it works quite well.

    WordPress 3.7.1
    Eazyest-Gallery 0.1.3

    When browsing thru the full screen pages with previous/next I noticed that the order was somewhat random, not in alphabetical or any other order. Digging thru the code I found that Eazyest_FolderBase::get_folder_images() just returns the files in readdir() order and doesn't sort.

    So in my installation I changed the code as follows:

    --- _ORIG_class-eazyest-folderbase.php	2013-11-01 16:52:53.000000000 +0100
    +++ class-eazyest-folderbase.php	2013-11-01 14:45:40.000000000 +0100
    @@ -1481,8 +1481,11 @@
           @closedir( $dir_content );
     		} else {
     	    return false;
    -		}
    -    return $this->folder_images['images'];
    +		}
    +		/**MJ: sort directory content**/
    +		sort($this->folder_images['images']);
    +		/**MJ**/
    +		return $this->folder_images['images'];

    May I suggest to include this in the release?


Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic