ImageBlock not working - http://www.studio4tattoos.co.uk/gallery2/

GazNicki

Joined: 2009-09-15
Posts: 36
Posted: Thu, 2010-02-18 14:16

I'm using the following echo:
echo mediaBlock(15, 'mode:dynamic g2_view:updates noLink:1 useThumb:1 useMicro:150');

Am I right in assuming that this will give me the most recent image to be uploaded to the album with the ID of 15??

What parameters can I use to tell it to get the most recent images from all albums in the gallery? Or would I have to make sub-albums in one parent-album?

TIA,

Gaz

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Thu, 2010-02-18 14:58

the root album's id is 7(unless you specify otherwise)

glad you got it working for your needs.

Now you need to embed the whole gallery and have mediaBlock link to the embedded gallery ;)

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

 
GazNicki

Joined: 2009-09-15
Posts: 36
Posted: Thu, 2010-02-18 15:58

Thanks :)

I have embedded the gallery now http://www.studio4tattoos.co.uk/gallery.php and made it blend into the website pretty well. I put the albums into one master album, but may change that back now and use ID=7 to use the root instead.

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Thu, 2010-02-18 16:15

if you change the embedUri in mediaBlockIncludes to http://www.studio4tattoos.co.uk/gallery.php it will generate links to the embedded gallery instead of the standalone.
not the g2Uri, just the embedUri

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

 
GazNicki

Joined: 2009-09-15
Posts: 36
Posted: Thu, 2010-02-18 16:17

Does that give any benefits??

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Thu, 2010-02-18 16:23
suprsidr wrote:
it will generate links to the embedded gallery instead of the standalone.

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

 
GazNicki

Joined: 2009-09-15
Posts: 36
Posted: Thu, 2010-02-18 16:26

lol, sorry about that. Yes, I see what you mean now hahaha.

Cheers :)

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Thu, 2010-02-18 17:14
 
lukedan

Joined: 2010-07-27
Posts: 52
Posted: Tue, 2010-07-27 19:52

Hi
I used on http://www.seibella.ro/test.html
<?php @readfile('http://www.seibella.ro/poze/mediaBlock.php?mode=dynamic&g2_view=dynamicalbum.RandomAlbum&limit=9&useThumb=1&column=3&useMicro=60');?>

<?php @readfile('http://www.seibella.ro/poze/mediaBlock.php?mode=dynamic&recursive=1&g2_view=dynamicalbum.UpdatesAlbum&limit=11&useThumb=1&column=4&rss=0');?>

First line with random is working ok

2-nd one with Updates not make anythink.

Any help?

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Tue, 2010-07-27 20:12

Make sure settings are correct in gallery admin -> Dynamic Albums -> Dynamic Album Settings

Beyond that, there does not appear to be any errors thrown, so you'd need to check server error logs.

BTW recursive=1 does not apply in dynamic mode.

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

 
lukedan

Joined: 2010-07-27
Posts: 52
Posted: Tue, 2010-07-27 20:18

Solved
"Dynamic Album Settings" should not have "use global" checked.

-My Gallery-
http://www.seibella.ro/poze

 
lukedan

Joined: 2010-07-27
Posts: 52
Posted: Tue, 2010-07-27 20:24

mmmmmmmm
It is not working only for new Albums. You should chose "show data items only" or "show all items"
I need that with new albums
help again

-My Gallery-
http://www.seibella.ro/poze

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Tue, 2010-07-27 20:30

I use show data items only, but mediaBlock honors the imageBlock disabled flag.
un-check Edit Album -> Album Tab -> Image Block -> Prevent this album from being displayed in the Image Block

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

 
lukedan

Joined: 2010-07-27
Posts: 52
Posted: Wed, 2010-07-28 07:08

Image Block
Prevent this album from being displayed in the Image Block
Apply ImageBlock settings to sub-albums

First was not checked but second yes on all albums. It is ok this?

-My Gallery-
http://www.seibella.ro/poze

 
lukedan

Joined: 2010-07-27
Posts: 52
Posted: Wed, 2010-07-28 15:30
 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Wed, 2010-07-28 15:35
suprsidr wrote:
Beyond that, there does not appear to be any errors thrown, so you'd need to check server error logs.

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

 
lukedan

Joined: 2010-07-27
Posts: 52
Posted: Wed, 2010-07-28 15:40

Sorry for this Q : Where are this error located?
-My Gallery-
http://www.seibella.ro/poze

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Wed, 2010-07-28 15:54

Your host should have given you access to some sort of error logs, or you may have to simply ask them if they can see some errors related to mediaBlock.php

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

 
lukedan

Joined: 2010-07-27
Posts: 52
Posted: Wed, 2010-07-28 19:55

Please be more exact;
- apache logs?
- gallery logs?
I have my own linux server

-My Gallery-
http://www.seibella.ro/poze

 
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 16504
Posted: Wed, 2010-07-28 19:57

Apache's error (not access) logs:
FAQ: What is the webserver error log?
____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

 
lukedan

Joined: 2010-07-27
Posts: 52
Posted: Wed, 2010-07-28 20:08

Erors in gallery:
Wed 28 Jul 2010 11:06:48 PM EEST PHP Error Link 78.97.80.129 [Notice] Undefined index: comment in file /var/www/gallery2_seibella/modules/rss/module.inc on line 80

Event Details
Date Wed 28 Jul 2010 11:06:48 PM EEST
Type PHP Error
Location http://www.seibella.ro/poze/main.php?g2_path=Modele-unghii-false-manichiura/09-04-Modele-unghii-false/Modele-unghii-manichiura-080.jpg.html
User Id 5
Client 78.97.80.129
Summary [Notice] Undefined index: comment in file /var/www/gallery2_seibella/modules/rss/module.inc on line 80
Referer http://www.seibella.ro/poze/Modele-unghii-false-manichiura/09-04-Modele-unghii-false/
Details

Undefined index: comment
Request variables: Array
(
[path] => Modele-unghii-false-manichiura/09-04-Modele-unghii-false/Modele-unghii-manichiura-080.jpg.html
[itemId] => 18476
[view] => core.ShowItem
)

-My Gallery-
http://www.seibella.ro/poze

 
lukedan

Joined: 2010-07-27
Posts: 52
Posted: Wed, 2010-07-28 21:05

No apache errors :(
-My Gallery-
http://www.seibella.ro/poze