eZ Community » Forums » General » eZFlow block: Is there a way to adda...
expandshrink

eZFlow block: Is there a way to adda checkbox for each block of an ezflow page?

eZFlow block: Is there a way to adda checkbox for each block of an ezflow page?

Friday 24 September 2010 6:19:35 am - 2 replies

Is there a way to add a checkbox for each block of an ezflow page? I ask because I would like to be able to check on or off whether to display dates next to headlines of articles if it is checked. The template override could then read this option in and decide whether to display or hide the dates.

Friday 24 September 2010 5:29:48 pm

Answer from Łukasz Serwatka on sdk-public:

This is possible but undocumented I'm afraid.

Example configuration is following:

[BlockTypeName]
CustomAttributes[]=my_checkbox
CustomAttributeTypes[my_checkbox]=checkbox

Supported values for CustomAttributeTypes are following: text, checkbox, string. If not defined then string is default value.

For checkbox type GUI will render regular checkbox button with values 0 or 1.

Then in templates you can use it like

{if $block.custom_attributes.my_checkbox|eq('1')}
checked!
{else}
unchecked!
{/if}

Hope this helps!

Monday 27 June 2011 1:30:14 am

Is it possible to add a ezoe editor?

expandshrink

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

36 542 Users on board!

Forums menu

Proudly Developed with from