Member
Member
bobearth   2008-10-17, 13:08
#1

I have an existing site that I'm trying to integrate with Zenphoto.

I have a plan for the way I [i]think[/i] it will work. See it here: http://thecanarystudio.info/zen-plan.jpg

Here's what I'm trying to do:

  1. Show albums as text links on all pages
  2. Show all sub-albums for the active album as thumbnails
  3. Show navigation for the active sub-album as numbered links
  4. Show the sized image on the same page as the above items

I've sorted out item 1, by using the print_album_menu plugin, all good there.
I've figured out how to show navigation as numbered text links.

Its item 2 that has me scratching my head, I really don't even know where to start on that one.

Any help/pointers would be greatly appreciated - I would also be more than happy to pay someone for their expertise (but above all, I would like to learn how this would be approached).

Administrator
Administrator
acrylian   2008-10-17, 13:23
#2

You can do 2. with this:
`

Member
Member
bobearth   2008-10-17, 14:14
#3

Thanks so much. So this script displays all sub-albums as thumbnails for the album (rather than a sub-album) I'm viewing?

Is there a way to show all sibling sub-albums that belong to the album I'm within? But as per my plan, while I am also viewing the list of top-level albums and seeing the sized images from the current sub-album. http://thecanarystudio.info/zen-plan.jpg

For example - on the site I'm working with: http://foodstylist.com.au/adspacks/a2_1.html
The grid of thumbnails = sub-albums that are the children of the 'ads+packs' album.
One of the sub-albums is active (name 'cottees' and represented by the second thumbnail, top row).

Member
Member
albeezie   2008-10-17, 14:56
#4

I think that the print_album_menu.php in the plugins folder can shed a lot of light on how to proceed.

Basically, you should call the top level album based on the $_zp_gallery and go from there.

Administrator
Administrator
acrylian   2008-10-17, 16:11
#5

The album menu has an option for showing only the toplevel albums. Then use the code above, that shows all direct subalbums of the album you are currently in.

Member
Member
bobearth   2008-10-20, 23:29
#6

thanks for your replies. The point I am struggling with is that I need all of this to happen on a single page: http://thecanarystudio.info/zen-plan.jpg

So I can show all subalbums of the album I am in, but what if I'm viewing a subalbum - how do I show the only the other subalbums which belong the same album (and also, how to represent each subalbum with a thumbnail).

thanks again for your help.

Member
Member
albeezie   2008-10-20, 23:46
#7

I am pretty sure that the print_album_menu plugin does pretty much what you are looking to do (it prints out the toplevel albums and subalbums of the topalbum as well as sister subalbums).. you just need to take that code and modify it to fit your needs.

Administrator
Administrator
acrylian   2008-10-21, 09:35
#8

@bobearth: I already posted the solution to show the subalbums of the current album. Take a look at our functions guide and the album class. There you will find all the methods (function) it provides that you can use as in my example above like $subalbumobj->.
There is also a method getParent() to get the object of the parent album of the current albums. The object that is returned can be used as the one in the example. Sorry, but you need to learn a few things about object orientated php. I hope you understand that we can't teach that here.

@albeezie: Adapting the album menu would probably work but that function is rather complicated because of the context sensitive display. The example above is basically what the the album menu uses.

Member
Member
albeezie   2008-10-21, 16:42
#9

Ah, that's a much easier way to go about it... go with acrylian!

Member
Member
bobearth   2008-10-21, 23:33
#10

Ah damn, this has quickly gone over my head - I'd be willing to pay for someone to create this theme for me. Any takers? Please contact me - tim [at] the canary studio [.] com

Cheers for all of your help.

Junior Member
Junior Member
pixelgrain   2009-02-12, 19:28
#11

Hey Ya'll...

I'm also looking to list sub-albums on the index page, and I've gotten far enough to show their thumbnails with the code here. But now I'm a bit stuck...

$subalbumobj->getAlbumThumb() WORKS GREAT
$subalbumobj->getAlbumTitle() DOES NOT WORK
echo $subalbumobj["name"]; ALSO NO GO

echo $subalbum will give me the filepath, so I have that and the thumbnail. All I need is the subalbum title.

Any ideas? I feel it should be pretty straight forward, but nothing seems to work.

Thanks...

Administrator
Administrator
acrylian   2009-02-12, 19:52
#12

You need to use the album class methods not the normal template-functions.
http://www.zenphoto.org/documentation/classes/Album.html
$subalbumobj->getTitle() will get the album title.

  
Powered By MyBB, © 2002-2026 MyBB Group.
Made with by Curves UI.