We've had to get at metadata category & keyword info before. Here's the code
we've had to use to get to the categories in an object:

***************

<!--- Get the objects --->
<cfa_contentobjectgetmultiple 
        datasource="#prgn_corp_db#" 
        typeid="D02ACB75-6FE0-11D4-9C160090277322BD" 
        r_qobjects="qPartners" 
        r_stobjects="stPartners"> 
        
<!--- Sort the objects --->
<cfa_structSortCommonSubkeys
    struct = "#stPartners#"
    commonSubKey = "label"
    r_aSortedKeys = "akey">

<!--- Loop through the objects --->
<CFLOOP list="#arraytolist(akey)#" index="ct">          
<cfoutput><h4>#stPartners[ct].label#</h4></cfoutput>
        <!--- Get the categories for Keywords for one object - This will
return the uuid's of categories assigned --->
        <cfset categorylist = #stPartners[ct].stkeywords['lcategories']#>
                <cfoutput>#categorylist#<br></cfoutput>
        <!--- counts the number of key word phrases in the object --->
        <cfset Stcount = StructCount(stPartners[ct].stkeywords)>
        <!--- Struct to a list --->
        <CFSET keysToStruct = StructKeyList(#stPartners[ct].stkeywords#,
",")> 
        <!--- gets us each key word including the label Lcat and displays
them --->
        <cfset stKeywords = StructNew()>
        <CFLOOP INDEX="LC" FROM="1" TO=#stcount#>
                <cfoutput><font
size="-1">#ListGetat(keysToStruct,LC)#</font><br></cfoutput>
                </cfloop>   
</cfloop> 

*****************
I think what you're going to need is the "structurename.stkeywords[]".

Then you have to loop through the stkeywords to display them.

Hope this is what you're looking for.

-Kate
-----Original Message-----
From: manoj singh [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, April 10, 2001 8:34 AM
To: Spectra-Talk
Subject: RE: Accessing values from an array....


Oh yeah I am 100% sure

In the dump, I see categories in blue and then the two values in green 
adjacent to it. Doesn't that mean it is an array ???


>From: "Raymond Camden" <[EMAIL PROTECTED]>
>Reply-To: [EMAIL PROTECTED]
>To: Spectra-Talk <[EMAIL PROTECTED]>
>Subject: RE: Accessing values from an array....
>Date: Tue, 10 Apr 2001 11:22:51 -0400
>
>Ah, so the error isn't with arraytolist, it's with stitems.categories. You
>said you did a cfa_dump on stitems and it had categories, are you 100% sure
>about that?
>
>=======================================================================
>Raymond Camden, Principal Spectra Compliance Engineer for Macromedia
>
>Email   : [EMAIL PROTECTED]
>ICQ UIN : 3679482
>
>"My ally is the Force, and a powerful ally it is." - Yoda
>
> > -----Original Message-----
> > From: manoj singh [mailto:[EMAIL PROTECTED]]
> > Sent: Tuesday, April 10, 2001 3:10 PM
> > To: Spectra-Talk
> > Subject: RE: Accessing values from an array....
> >
> >
> > Ray,
> >
> >    I tried this too
> >
> > <cfset lcategories = arrayToList (stitems.categories)> but no luck.
> >
> >
> > The exact error is as follows
> >
> > Error Diagnostic Information
> >
> > An error occurred while evaluating the expression:
> >
> >
> > lcategories = arrayToList (stitems.categories)
> >
> >
> >
> > Error near line 10, column 9.
> > ------------------------------------------------------------------
> > --------------
> >
> > Error resolving parameter STITEMS.CATEGORIES
> >
> >
> > The object CATEGORIES is not present in the scope named STITEMS. It is
> > likely that you have misspelled the name of the object you are trying to
> > access.
> >
>
>
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm
------------------------------------------------------------------------------
To Unsubscribe visit 
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/spectra_talk or send a 
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.

Reply via email to