This site has been archived. To learn more about our current products Ibexa Content, Ibexa Experience, Ibexa Commerce head over to the Ibexa Developer Portal

eZ Community » Forums » Extensions » eZ Flow » Allow class to keep multiple...

Allow class to keep multiple zone-setups if it has more than one layout field

Allow class to keep multiple zone-setups if it has more than one layout field

Friday 23 November 2012 5:40:28 pm - 2 replies

Hello community! 

I'm running ezpublish version Community Project 2012.8  with the ezflow extension. I'm currently working on a page with the follwing requirement:

On a frontpage with an ezflow-layout i need to have two different layouts at the same time. All well and good so far, i just add two layout fields in my frontpage-class.
The problem now is, i need the ability to switch automatically between these two (via the value of a checkbox for example). But i can only fill one layout field with blocks! as soon i try to set the other layout in order to fill it with blocks, ezflow discards the zone/block-setup of the field i filled previously. So i will always have only one layout available, as the datatype appearently allows only one set of blocks to be added to the zones/layout. 

Does anyone know a good workaround for this, or a solution to this in general? 
I tried to create my own datatype by copying the files i thought which were necessary (datatpyes/ezpage/ezpagetype.php and classes/ezpage.php) and renamed them, but the new datatpye wouldn't show up. 
I tried to hack the ezflow ezpage datatype, but gave up for this one...

Help is much appreciated!! Thanks in advance!


Modified on Friday 23 November 2012 5:41:50 pm by Pirmin Schneider

Tuesday 27 November 2012 11:28:05 am

1. maybe you can fill in a feature-request in Jira for ez to properly support using 2 layout attributes within the same content object

2. workaround: can you create a 2nd object with the 2nd layout attribute, have the editor manage them separately, and in the tpl display the layout attribute from it instead of the one from the main node based on the value of a checkbox attribute?

Tuesday 04 December 2012 1:50:36 pm

Thank you for your answer, Gaetano!

I didn't know about Jira. It looks quite interesting, i haven't found a way to fill in feature request, though. Bit i'll have another look at it some time.

Your second point sounds interesting, but unfortunately the site's architecture is complex, thus it wouldn't be very editor friendly to have more than one node for each of the affected nodes. but it could be an emergency solution.
i thought about having the editor prepare two versions of the same node, and use ezpublish's time scheduled publish/unpublish feature to switch between the two versions.

does that sound feasible?

Modified on Tuesday 04 December 2012 1:51:19 pm by Pirmin Schneider


You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu

Proudly Developed with from