I am using coldfusion's imageGetIPTCMetadata() function to get the iptc keywords. 

I used Photomechanics to insert some keywords in a hierarchical fashion like this 

```
Personnel   |   Appointments   |   Assistant Chief of General Staff (ACGS), Personnel  |  Ranks  |  Royal Marine  |  Colour Sergeant (CSgt), Personnel | Ranks | Royal Navy | Chief Petty Officer (CPO), Personnel|Ranks|Army|Field Marshall (Fd Marshall) (FM)

```

But after I call the method in my CFC I get this - 

How can I get the keywords with a delimeter or something so that I can reuse them in my code.

![enter image description here](https://i.stack.imgur.com/Tiy4o.png)
['https://Stackoverflow.com/questions/9131483', 'https://Stackoverflow.com', 'https://Stackoverflow.com/users/418366/']
I found the solution [here](http://www.genuinejd.com/blog/index.cfm/2009/2/20/Reading-Embedded-XMP-Packets-using-ColdFusion): 

```xml
<cfparam name="URL.source" default="xmp-asset.jpg">
<cffile action="readbinary" file="#ExpandPath(URL.source)#" variable="data">
<!-- encode the binary data to hex -->
<cfset hex_data = BinaryEncode(data,"hex") />
<!-- string indicating beginning of packet '<x:xmpmeta' -->
<cfset xmp_string_begin = "3C783A786D706D657461" />
<!-- string indicating end of packet '</x:xmpmeta>' -->
<cfset xmp_string_end = "3C2F783A786D706D6574613E" />
<!-- find the starting index in the hex string -->
<cfset idx_start = FindNoCase(xmp_string_begin,hex_data) />
<!-- find the ending index in the hex string -->
<cfset idx_end = FindNoCase(xmp_string_end,hex_data,idx_start) + Len(xmp_string_end) />
<!-- using the start and end indices, extract the xmp packet -->
<cfset xmp_hex = Mid(hex_data,idx_start,Evaluate(idx_end-idx_start)) />
<!-- convert the hex to readable characters -->
<cfset xmp_string = ToString(BinaryDecode(xmp_hex,"hex")) />
<!-- parse the xml string to and xml structure -->
<cfset xmp_xml = XmlParse(xmp_string) />
<cfcontent type="text/xml">
<cfoutput>#xmp_string#</cfoutput>

```

Now I can get the entire XMP xml and do all I want to do with the data there.
I use CFX\_OpenImage to read and write IPTC\_ data in .jpg files in CF8 thru CF11. I also use this for image resize and rotation.

More CFX\_OPENIMAGE INFO go to <http://www.kolumbus.fi/jukka.manner/cfx_openimage/>

It GraphicsMagick 1.3.17.  

GraphicsMagick (www.graphicsmagick.org) maintains a stable release branch, maintains a detailed Change Log, and maintains a stable source repository with complete version history so that changes are controlled, and changes between releases are accurately described. GraphicsMagick provides continued support for a release branch.  

More INSTALLATION INFO:

Note: If you are installing 64bit version of the tag, please download and install Microsoft Visual C++ 2010 Redistributable Package (x64) from Microsoft (<http://www.microsoft.com/download/en/details.aspx?id=14632>). The x64 version has been compiled and written in Visual Studio 2010.  

CFX\_OPENIMAGE installation steps common to both versions:  

Create an environment variable Since GraphicsMagick needs read configuration files (\*.mgk files), we need to tell the tag where those files are located. In order to do that, a system or cold fusion runtime user specific environment variable must be set. The name of this variable is CFX\_OPENIMAGE\_FULLPATH.  

CFX\_OPENIMAGE\_FULLPATH environment variable should contain full pathname which points to a directory where all mgk-files and cfx\_openimage.ini file are kept. A default value for this is “c:\cfx\_openimage\”. Notice that the last “\” character is needed too.  

You may install the actual dll where ever you like, it’s up to you to register is anyway via CF admin page. For keeping the security settings for all the files equal, it is recommended to keep cfx\_openimage.dll in the same directory that the \*.mgk and cfx\_openimage.ini directory.