view album externally

kasapo

Joined: 2010-12-16
Posts: 2
Posted: Thu, 2010-12-16 19:16

Hi, I'm trying to do something that should be fairly simple.

I have an album in gallery. I have PHP web application on another machine, that does not share the gallery code. I need to use the readfile / imageBlock mechanism for loading files in the outside web application.

So far I'm using this:

@readfile("my.domain.tld/gallery2/main.php?g2_view=imageblock.External&g2_blocks=specificItem&g2_itemId=4672&g2_maxSize=225&g2_show=fullSize&g2_show=title")

Which is ok, it pops up the image I need in the external application. However, the itemID provided is the album's ID.

I was hoping to be able to display a row of images in that gallery. I have tried the mediaBlock.php script from flashyourweb (http://www.flashyourweb.com/staticpages/index.php?page=mediaBlock), but this returns the entire page in embedded form (i just need the row of images -- the actual album).

I would rather not have to keep track of the IDs of the images that we want in this external application, but rather just provide the album ID and list all (or a set number of) the images in that album.

So, rather than (A) creating a "blank" theme that just allows the album's imageblock to be returned using mediablock, or (B) adding one @readfile() statement per image (and maintaining this as images change...) does anyone have any ideas that will let me display all the images in some album?

Thanks,
kasapo

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Fri, 2010-12-17 00:37

mediaBlock does just what you're requesting, I'm not sure what you mean when you say

Quote:
this returns the entire page in embedded form

That is not how mediaBlock functions. It is not aware of any of gallery's html for header/sidebar/footer etc.

Can you provide a link to the offending page?

-s
FlashYourWeb and Your Gallery with The E2 XML Media Player for Gallery2