detect "parent" object in embeded object template

Author Message

Marko Žmak

Thursday 28 January 2010 4:11:54 am

I have an object (object A) embeded in OE field of another object (object B), and I have a template override for this embeded object A. How can I detect in this template what is the the object_id of the object B?

--
Nothing is impossible. Not if you can imagine it!

Hubert Farnsworth

Bertrand Dunogier

Thursday 28 January 2010 7:25:22 am

You can get a variable from the parent's template namespace using the # sign. If the variable you're looking for is $object_id, this is what it would look like:

$#object_id

Bertrand Dunogier
eZ Systems Engineering, Lyon
http://twitter.com/bdunogier
http://gplus.to/BertrandDunogier

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.