Quantcast
Channel: Question and Answer » json
Browsing all 148 articles
Browse latest View live

Search and replace image src from JSON [on hold]

I am trying to write a simple module that will check nodes and if a node has field “body” to execute the str function and change default drupal root sign to $base_url. This is what I tried, but it...

View Article


Best way to represent multiple JSON response in a REST service? [closed]

I am working on a REST service in which I am trying to come up with a JSON response that I am supposed to return back. Below is the design I am able to come up with in which each line is a response for...

View Article


Best way to structure a complicated web-based quiz [closed]

I have a web project that requires I build a quiz and am having some difficulty working out how to efficiently code it. I’d like to create some sort of json template system so that the quizzes can be...

View Article

Sharepoint don't get JSON with IE9

I have a small AngularJS Application in SharePoint 2013, where I get a JSON File from an asmx WS to show. The Application runs fine, except with IE9 on SharePoint. All other Browser don’t have any...

View Article

Custom Permalinks for JSON Feed

What file-name would I make to allow the following permalink. WordPress/Custom-Archive/ID/Title I have created the Custom-Archive with achive-slug.php and the ID seemed to work under that as well but...

View Article


Summing values from JSON end point based on category [closed]

I have a JSON end point for projects in a county. I am able to call a list of any of the object properties. What I want to do is to add together either all the values of budget property or the...

View Article

Declarative parser for JSON and DOM

I am parsing many JSONs and DOMs in PHP. The problem is that the my knowledge about the structure of the JSON/DOM is mixed with code. For example, suppose that I have few sources of first and last...

View Article

How to print Json data from Facebook in a block?

I would like to print the amount of Facebook likes for a url into a block. The Facebook API returns JSON like so:...

View Article


Search a content type and return JSON [duplicate]

This question already has an answer here: search results in JSON format 1 answer

View Article


XMLstarlet for JSON?

Is there a tool that is similar to XMLstarlet but works on JSON instead of XML? My usecase: extract certain values from hierarchical JSON documents, as they are returned by some REST APIs. Something...

View Article

What is the best way to encrypt a json object in Java?

I have a Json array JsonArray people; which holds JSON objects representing people. Currently I am saving them as plaintext in a json file. try { OutputStream out = new...

View Article

Cache Json on disk with fast read back in java/android

summary: I need a way to cache a large JSONArray on disk, and be able to quickly read AND CONVERT it back to JSONArray at a later time. NOTE: my output MUST be a >>JASONarray<<, and not a...

View Article

return content section as json in wp rest api v1

I am using WP REST API. I want to get the posts from my blog and show them in my android app. So, everything is OK, but i need to ask a question to make sure about something: when i call posts in the...

View Article


WordPress REST API not returning all posts

I am trying to get the json data of my posts. I have tried with both v1.2.4 and v2 of the REST API plugin. If I enter http://example.com/wp-json/posts?type=magazine or...

View Article

Postgres query to return JSON object keys as array

Is it possible to return a JSON object keys as an array of values in PostgreSQL? In JavaScript, this would simply be Object.keys(obj), which returns an array of strings. For example, if I have a table...

View Article


PostgreSql : flatten json array data

From my current query, I obtain this jsonb data : values: "a1", ["b1", "b2"] And I want to flatten it on one level only, like this : values: "a1", "b1", "b2" Here is a simplfied way to get data in a...

View Article

Image may be NSFW.
Clik here to view.

WF gets canceled status while WS call

I’ m trying to call HTTP WS from WF. Unfortunately, it gets canceled every time and I can’t understand a reason. In a browser service works fine. Would you mind telling me what’s wrong? WS source code:...

View Article


Turn Drupal into a USER API

I’m developing the main website (A) for an organisation in D7 but for other reasons there are microsites (B) related to this website using CMSs. I need to give this other users an endpoint in which...

View Article

JSON API specification : When do I need to return a 404 not found?

I’m working on a REST api following the JSON api specification and I’m struggling with the “no data” responses (described here). A server MUST respond with 404 Not Found when processing a request to...

View Article

“Industry Standard” JSON formats for game assets

This question is inspired by my venture into the Phaser game engine but seems to apply to any engine that uses JSON for its asset format. Phaser relies on PhysicsEditor to export and create the JSON...

View Article
Browsing all 148 articles
Browse latest View live