Skip to main content
Inspiring
July 17, 2019
Answered

Get data from deserializeJSON

  • July 17, 2019
  • 1 reply
  • 1009 views

I am a bit lost on how to get the data out of a structure created from deserializeJSON. I am trying for example to set Results = data / array1 / doc / m.

So along the lines of <cfset results = #data.doc.m[1]#> but that's not right... What's the proper way to do this?

When I dump the results the look like:

    This topic has been closed for replies.
    Correct answer WolfShade

    It's been a while since I've worked with JSON, but try:  data[1].doc.m

    V/r,

    ^ _ ^

    1 reply

    WolfShade
    WolfShadeCorrect answer
    Legend
    July 17, 2019

    It's been a while since I've worked with JSON, but try:  data[1].doc.m

    V/r,

    ^ _ ^

    ghanna1Author
    Inspiring
    July 17, 2019

    Thanks!  That did it.

    WolfShade
    Legend
    July 17, 2019

    Awesome!  Glad I could actually remember that.  And glad that you got it working.

    And thank you for marking my answer as correct.  I do appreciate it.

    V/r,

    ^ _ ^