Announcement

#1 2019-05-21 22:25:06

EdwinKort
Translation Team
Rhoon, the Netherlands
1970-01-01
95

[Personal Plugin] Max. numbers of images on a page

Hello/Hi/Greetings,

I found this on

Code:

<?php
/*
Plugin Name: Custom photo number
Version: 1.0
Author: ddtddt & Mistic
*/
 
add_event_handler('loc_begin_index', 'modifynbthumbnail');
 
global $customPhotoNumber;
 
$customPhotoNumber = array(
  1 => 5, // 5 photos per page for album #1
  2 => 10, // 10 photos per page for album #2
);
 
function modifynbthumbnail()
{
  global $page, $customPhotoNumber;
 
  if (!empty($page['category']['id']) && isset($customPhotoNumber[$page['category']['id']]))
  {
    $page['nb_image_page'] = $customPhotoNumber[$page['category']['id']];
  }
}

But do I have to set a number for all folders? As in:
$customPhotoNumber = array(
  1 => 5, // 5 photos per page for album #1
  2 => 10, // 10 photos per page for album #2
);

Or is there a way to set the max. number for all folders?


My Gallery
Hosted with: Surpass Hosting since 2004

Offline

 

#2 2019-05-28 20:04:51

eliz82
Member
Romania
2016-04-27
262

Re: [Personal Plugin] Max. numbers of images on a page

EdwinKort wrote:

Hello/Hi/Greetings,
Or is there a way to set the max. number for all folders?

they buried this options deep in the menu for recent Piwigo versions.

go to user groups, click for example "guest", then click edit. now you can set default value for guest.

Offline

 

#3 2019-05-30 18:12:08

EdwinKort
Translation Team
Rhoon, the Netherlands
1970-01-01
95

Re: [Personal Plugin] Max. numbers of images on a page

Thanks. Already found it, but forgot to mention it here.


My Gallery
Hosted with: Surpass Hosting since 2004

Offline

 

Board footer

Powered by FluxBB

github twitter facebook google+ newsletter Donate Piwigo.org © 2002-2019 · Contact