fetch( 'content', 'contentobject_attributes', hash( 'version', version, [ 'language_code', language_code ] ) )
Name | Type | Description | Required |
---|---|---|---|
version | object | The target version (must be an ezcontentobjectversion object). | Yes. |
language_code | string | The language code. | No. |
An array of ezcontentobjectattribute objects or FALSE.
This function fetches the attributes that belong to a certain version. The version must be provided (as an ezcontentobjectversion) using the "version" parameter. The "language_code" parameter is optional and can be used to get the attributes that belong to a specific translation. The function returns an array of ezcontentobjectattribute objects or FALSE if something went wrong.
{def $object=fetch( 'content', 'object', hash( 'object_id', 14 ) ) $attributes=fetch( 'content, 'contentobject_attributes', hash( 'version', $object.current ) )} {foreach $attributes as $attribute} {$attribute.data_type_string} <br /> {/foreach}
Outputs the names of the datatypes that are used by the different attributes within the current version of object number 14.
Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2013 eZ Systems AS (except where otherwise noted). All rights reserved.