Announcement

#1 2020-08-25 12:05:51

Undergrid
Member
2019-03-13
25

One album in multiple places

Hi,

I know you can have a picture associated with multiple albums, but I'm wondering if there's a way to have a sub-album any items contained within) associated with multiple parent albums?

Thanks

Piwigo version: 2.10.2
PHP version: 7.0.33-0+deb9u3
MySQL version: 5.5.5-10.1.38-MariaDB-0+deb9u1

Offline

 

#2 2020-08-25 21:58:03

executive
Member
2017-08-16
1214

Re: One album in multiple places

Smart albums extension and keywords

Offline

 

#3 2020-08-26 15:16:32

Undergrid
Member
2019-03-13
25

Re: One album in multiple places

That works, but it flattens the album hierachy under the selected album and I was hoping to maintain that structure.

Offline

 

#4 2020-08-29 16:56:55

Aevaris
Member
2020-08-23
13

Re: One album in multiple places

I haven't tried it, but I bet you could create a symlink to achieve this.

In a folder structure such as:
/mydir/my album A/my pic.jpg
/myseconddir/my album B/my other pic.jpg

And you want to display "my album A" under "myseconddir" alongside "my album b", you could just make a symlink of:
ln -s "/mydir/my album A" "/myseconddir/my album A"

piwigo should pick up your "duplicate" my album A as a new directory but have the same files.

Offline

 

#5 2020-08-31 16:01:35

deheme
Member
France
2014-12-12
104

Re: One album in multiple places

Hello,

Did you investigate the plugin extended description with the [redirect cat=xx]?

or, with a bit of JS
Create the fake album, with one picture only and in its description add the following code

Code:

Redirection ...<!--more--><script type="text/javascript">self.location.href='your_album_url'</script>

you need extended descripton plugin.

Enjoy!
DéHème

Last edited by deheme (2020-08-31 16:13:24)

Offline

 

#6 2020-09-18 13:40:45

Undergrid
Member
2019-03-13
25

Re: One album in multiple places

deheme wrote:

Hello,

Did you investigate the plugin extended description with the [redirect cat=xx]?

I have never gotten this to work and I'm not exactly sure what I'm supposed to do with it or how it's supposed to work.

If I put the redirect in the description of an album, well nothing seems to happen.  I still see the original albums content (I had to put one image in there to get the album to apear) when I click on the album.  I am using bootstrap_darkroom, so I don't know if that's the issue...

I know extended description is working since putting the hidden tag in an album title does hide it.

deheme wrote:

or, with a bit of JS
Create the fake album, with one picture only and in its description add the following code

Code:

Redirection ...<!--more--><script type="text/javascript">self.location.href='your_album_url'</script>

you need extended descripton plugin.

Enjoy!
DéHème

This does work, but it kind of breaks the back button (you need to press it twice) and I was hoping for something that would display the image count of the destination album and a cover image from that album on the parent album page.

Offline

 

#7 2020-09-18 13:42:22

Undergrid
Member
2019-03-13
25

Re: One album in multiple places

Aevaris wrote:

I haven't tried it, but I bet you could create a symlink to achieve this.

In a folder structure such as:
/mydir/my album A/my pic.jpg
/myseconddir/my album B/my other pic.jpg

And you want to display "my album A" under "myseconddir" alongside "my album b", you could just make a symlink of:
ln -s "/mydir/my album A" "/myseconddir/my album A"

piwigo should pick up your "duplicate" my album A as a new directory but have the same files.

This would work, but would artificailly inflate the image count of the site.  I'll keep it as a last resort thought.  Thanks.

Offline

 

#8 2020-09-18 14:22:55

deheme
Member
France
2014-12-12
104

Re: One album in multiple places

Undergrid wrote:

deheme wrote:

Hello,

Did you investigate the plugin extended description with the [redirect cat=xx]?

I have never gotten this to work and I'm not exactly sure what I'm supposed to do with it or how it's supposed to work.

Hello, it does work, also with Darkroom. However the result cannot be seen if you are logged admin. With another user logged, it works. I'm not sure the pict number is the right one as you'd would like!

Another solution is to make use of smart album plugin. You may define an album with X photos selected in another album. My experience is that its generates additional load on the server (Just an impression however). Give it a try, be careful it's a bit tricky.

Note : I've the impression symlinking will not work...but I'm not aware enough.

Enjoy!
Déhème
PS : Sorry for my FrenGlish

Offline

 

#9 2020-09-18 17:56:24

Undergrid
Member
2019-03-13
25

Re: One album in multiple places

deheme wrote:

Undergrid wrote:

deheme wrote:

Hello,

Did you investigate the plugin extended description with the [redirect cat=xx]?

I have never gotten this to work and I'm not exactly sure what I'm supposed to do with it or how it's supposed to work.

Hello, it does work, also with Darkroom. However the result cannot be seen if you are logged admin. With another user logged, it works. I'm not sure the pict number is the right one as you'd would like!

Another solution is to make use of smart album plugin. You may define an album with X photos selected in another album. My experience is that its generates additional load on the server (Just an impression however). Give it a try, be careful it's a bit tricky.

Note : I've the impression symlinking will not work...but I'm not aware enough.

Enjoy!
Déhème
PS : Sorry for my FrenGlish

Ah, that's why I could never getting it working.  It does work when not logged in as Admin.  Thanks!

Offline

 

Board footer

Powered by FluxBB

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