Closed (fixed)
Project:
Views Datasource
Version:
7.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
5 Mar 2012 at 18:43 UTC
Updated:
3 May 2012 at 06:30 UTC
In a json output is there a way to remove the double-quotes from the root object name and field labels? For example, views exports the following format regardless of format setting:
{
"items": [
{ "label": "John Doe",
"type": "Person",
"nid": "36"
}
]
}
I need the double-quotes omitted from items, label, type and nid as shown here. Meaning only the string values should have the double-quotes.
{
items: [
{ label: "John Doe",
type: "Person",
nid: "36"
}
]
}
I checked the module's files, including the theme and plugins subdirectories but nothing jumped out at me.
Also refer to this external ref:
http://simile.mit.edu/wiki/Exhibit/Creating,_Importing,_and_Managing_Data
Thank you,
George Aiello
Comments
Comment #1
gaiello commentedBumping... as a last try to see if anyone has an idea on this before we resort to building our own PHP extracts. Thanks in advance.
-George Aiello
Comment #2
jimthunderbird commentedOne way to do it will be:
Comment #3
gaiello commentedThank you Jim. I have one of our developers looking at your suggestion and will report back once I know how it goes.
-George Aiello
Comment #4
gaiello commentedIt turns out we made a mistake elsewhere in the destination for the json data (Sencha Touch 2) and the problem wasn't in views_datasource at all. Everything is working fine with this module for us now. My bad. Sorry.
-George Aiello
Comment #5
rooby commentedThis has been reported as fixed.