Announcement

  •  » Engine
  •  » Current category ID

#1 2018-04-18 16:59:13

gandycz
Member
2015-03-29
27

Current category ID

Hello/Hi/Greetings,


Is there any way to get current category ID in template? I want to pass this ID to Carousel so it will show on album just pictures from current album user visited.


Thanks

Piwigo version: latest
Piwigo URL: http://iphoto.macweb.cz

Offline

 

#2 2018-04-18 19:22:57

ddtddt
Piwigo Team
Quetigny - France
2007-07-27
7198

Re: Current category ID

Hi :-)

in php
global $page;
$page['category']['id'];


You love Piwigo so don't hesitate to participate, learn more on the "Contribute to Piwigo" page. If you don't have much time for contribution, you can also help the project with a donation.

Offline

 

#3 2018-04-18 21:03:57

gandycz
Member
2015-03-29
27

Re: Current category ID

Thanks men now i have it there:

$template->assign('page_id', $page['category']['id']);

cool now i can do the tricks...

Offline

 

#4 2018-04-18 21:11:31

gandycz
Member
2015-03-29
27

Re: Current category ID

great thank you again now it's working as I wanted.

Offline

 

#5 2018-04-18 22:35:17

ddtddt
Piwigo Team
Quetigny - France
2007-07-27
7198

Re: Current category ID

:-)

link demo ?


You love Piwigo so don't hesitate to participate, learn more on the "Contribute to Piwigo" page. If you don't have much time for contribution, you can also help the project with a donation.

Offline

 

#6 2018-04-18 22:56:01

gandycz
Member
2015-03-29
27

Re: Current category ID

Piwigo URL: http://iphoto.macweb.cz

that Carousel on top is now changing when user enter a subs. From mobile devices also but with different style and supports slideleft(),slideright()

Offline

 

#7 2018-04-18 23:19:11

ddtddt
Piwigo Team
Quetigny - France
2007-07-27
7198

Re: Current category ID

you're make a plugin ?


You love Piwigo so don't hesitate to participate, learn more on the "Contribute to Piwigo" page. If you don't have much time for contribution, you can also help the project with a donation.

Offline

 

#8 2018-04-18 23:50:28

gandycz
Member
2015-03-29
27

Re: Current category ID

no I just replace that old random image plugin with something that work with bootstrap. ;)

Offline

 

#9 2018-04-18 23:53:38

gandycz
Member
2015-03-29
27

Re: Current category ID

this is just a “jumbotron” with Carousel and little bit of javascript,css magic :) it is actually in help from that theme but it must be tuned up for use. That theme have a lot of strange errors...

Offline

 
  •  » Engine
  •  » Current category ID

Board footer

Powered by FluxBB

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