Announcement

#1 2015-03-13 08:30:29

leonardo.g
Member
Italia
2015-03-09
12

1 site, 2 gallery

Hi,

I would like to make a plug-in that is filtering categories depending on the value of site

For the categories menu is simple:
(ex.)

Code:

add_event_handler('get_categories_menu_sql_where', 'filterbys_begin_index'  );

function filterbys_begin_index($where)
{
  
  $where .= "AND site_id =2";
  return $where;
  }

but do not know how to intercept and modify thee where that allow to select the categories in the rest of the frontend ....
someone would give me a tip on various event_handler?

thank you

Piwigo version: 2,7

Last edited by leonardo.g (2015-03-13 10:39:25)

Offline

 

#2 2015-03-26 07:51:00

leonardo.g
Member
Italia
2015-03-09
12

Re: 1 site, 2 gallery

I wrote a new plugin to create multiple galleries in the same installation.
We can open the site with a parameter (sitename) to see some categories (and not others) with a optional different title and a different theme.
In the moment I have not entered an interface for administrator (to change name, title and theme)
Someone wants to work with me?

Offline

 

#3 2015-03-27 09:56:00

plg
Piwigo Team
Nantes, France, Europe
2002-04-05
13791

Re: 1 site, 2 gallery

Hi leonardo.g,

That is very interesting.

Did you also study the multisite feature of Piwigo? (this is the feature used on Piwigo.com)

Offline

 

Board footer

Powered by FluxBB

github twitter newsletter Donate Piwigo.org © 2002-2024 · Contact