Object relation
Summary
Stores a relation to a content object.
Properties
| Name | Internal name | Searchable | Information collector |
|---|---|---|---|
| Object relation | ezobjectrelation | Yes. | No. |
Description
This datatype allows the relation of a single object. The following screenshot shows the class attribute edit interface for this datatype.
Class attribute edit interface for the "Object relation" datatype.
Object attribute edit interface
The following screenshot shows the object attribute edit interface for this datatype.
Object attribute edit interface for the "Object relation" datatype.
Raw output
The ".content" of an ezcontentobjectattribute object using this datatype returns either FALSE (if there is no relation) or an ezcontentobject object.
Contributors
- Balazs Halasy Updated
- Nathan Kelly Commenter
- Kristof Coomans Commenter
- Mike LECOMTE Commenter
- Squeegie Commenter
- André Rømcke
Comments (8 historical)
Written by readers of the earlier documentation sites, kept as they were.
What are the "Default Selection Item" and "Allow Fuzzy Match" attributes for?
Nathan Kelly ·
Could you please expand the description of the "Object Relation Datatype" edit interface?
I have tried using the "Default Selection Item" in the hope it would allow me to browse directly to the "Images" folder within the "Media" folder when inserting images into articles for example, but it didn't seem to work.
Have I misunderstood the purpose of this attribute?
Also could you explain what the "Allow Fuzzy Match" checkbox is for? What is "Fuzzy Matching"?
It seems that some of the "New" documentation assumes the reader already knows almost everything about EzPublish, but for those of us who are new to EzP (or the concept of CMS) the under exemplified descriptions on some pages equate to quite a lot of time wasting searching for the answers elsewhere.
I'm not asking for a bible and I'm not having a dig at all of the hard work that has gone into this documentation, I just think some more enlightened examples and descriptions would make EzP far more user friendly. On that note I think for the best part you are doing a great job on the Docs.
Cheers!
Re: What are the "Default Selection Item" and "Allow Fuzzy Match" attributes for?
Kristof Coomans ·
The default selection item is the one of which the child nodes will be fetched to put in the drop-down list when the selection method is drop-down list.
When the fuzzy-match option is checked, an additional text field will be shown where you can enter some text. When storing the object the system will then choose a related object based on the text you entered.
INI-based limitations with browse selection method
Kristof Coomans ·
If you choose the selection method "browse", you can configure which browse type has to be used with an undocumented setting in content.ini:
Where 240 is the class attribute id and AddRelatedImageToDataType is the browse type (this type can be configured in browse.ini).
If for a specific class attribute no browse type has been specified, AddRelatedObjectToDataType is used.
The Object relation list datatype uses the same settings, but the default browse type is AddRelatedObjectListToDataType.
Re: INI-based limitations with browse selection method
Kristof Coomans ·
See also: http://ez.no/community/forum/gene...objects_at_once_for_object_relations
Example code to fill an attribute of this datatype with PHP
Kristof Coomans ·
see http://ez.no/community/forum/deve...n_attribute_type_within_a_php_script
Exemple of raw output of an object relation attribute to an image
Mike LECOMTE ·
{$node.object.data_map.my_objetc_relation.content.data_map.image.content[original].full_path}
Re: Exemple of raw output of an object relation attribute to an image
Squeegie ·
what is ".my_object_relation." in the raw output ?????
Thanx
Re: Re: Exemple of raw output of an object relation attribute to an image
André R. ·
its an example of the attribute identifier of an object relation attribute.