Share » Forums » Developer » Best way to query for attribute ID?

Best way to query for attribute ID?

Best way to query for attribute ID?

Wednesday 05 May 2010 8:38:22 pm - 2 replies

Modified on Wednesday 05 May 2010 8:46:51 pm by Russell Michell

Author Message

Bertrand Dunogier

Thursday 06 May 2010 1:36:48 am

You can use the API for that. It would even work as a one-liner, but some error control wouldn't hurt :-)

$attribute = eZContentObjectAttribute::fetch( $attributeID )
             ->attribute( 'contentobject_id' );

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

André R.

Thursday 06 May 2010 3:25:39 am

"SDK":

http://pubsvn.ez.no/doxygen/trunk/html/index.html

(Change 'trunk' with version if you want, but trunk has always "best" doc as we continually improve it as we change it from doxygen to phpdoc syntax we tend to improve it while at it)

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

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

36 542 Users on board!

Forums menu