• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

CF 10 - deserializeJSON

Guest
Apr 29, 2013 Apr 29, 2013

Copy link to clipboard

Copied

Hi,

in CF 9 I could do

<cfset test = '[{"key1":"value1", "key2":12345, "key3":{"nestedkey1":"nestedvalue1", "nestedkey2":"nestedvalue2"}}]' />

<cfset deserialized = deserializeJSON(test) />

<cfdump var = "#deserialized#" />

and would get a coloured box with the various components of test. With CF 10 all I get is a string with the contents of test. What do I need to do differently in CF 10 to get the coloured box again and - most importantly - to be able to access the parts of the (what I thought it should be) struct resulting from deserializeJSON?

TIA.

Views

472

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Enthusiast ,
Apr 30, 2013 Apr 30, 2013

Copy link to clipboard

Copied

Your code example works just fine with me. Tested it with CF10 under RHEL, all the latest updaters installed.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
Apr 30, 2013 Apr 30, 2013

Copy link to clipboard

Copied

LATEST

So it seems to be a problem with the Mac version.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation