Callback problem
vfortin
Joined: 2007-05-23
Posts: 8 |
Posted: Sun, 2007-06-03 21:27 |
Hi there, Following the instructions on this page: But when I call it with {g->callback type="core.LoadChildren" item=$item|default:$theme.item I get this error message: Notice: Undefined index: core
This is likely a PHP/Smarty newbie error. Thanks! |
|
Posts: 32509
your example is missing the closing "}" curly bracket.
> Notice: Undefined index: core
isn't that accompanied by a file / line number? check your code in Callbacks.inc, and the code you added in the .tpl file.
--------------
Documentation: Support / Troubleshooting | Installation, Upgrade, Configuration and Usage
Posts: 8
Thanks valiant,
You're right, something is wrong about my code.
The callback I'm trying to write is nothing more than a modified LoadPeers. I want to retrieve the album children instead of the peers.
I'm suspecting one of the GalleryCoreApi function to return an empty array but my PHP knowledge stops here.
Can you tell what I'm doing wrong?
This is the call from the album.tpl:
...and this is the callback:
EDIT: Btw I only messed with the first statements to pass the $item instead of the $parent. My problem probably lies somewhere around here.
Posts: 205
Did you manage to get LoadChildren to work?
Posts: 8
Nope, sorry.
I think it goes against the natural workflow of the software.
All my questions regarding this here remained unanswered.
Posts: 205
Found a soution for our problem http://gallery.menalto.com/node/44573#comment-250873.