JSON (JavaScript Object Notation) aka the Fat Free Alternative to XML is a lightweight data exchange format inspired by JavaScript object literals. It is often used with JavaScript, Ajax, and RESTful web services but is completely language independent.

learn more… | top users | synonyms

4
votes
2answers
131 views

ToDoApp with persistence (using JSON)

This is a simple ToDoApp with a CLI that is made useful by adding persistence. A shout out to @Phrancis and @syb0rg for guiding this little project to where it is now. The structure is rather simple. ...
0
votes
1answer
22 views

Condense JSON for bandwidth efficiency

JSON is quickly becoming the formatting standard of choice for quick, convenient, and reliable machine to machine communications. It is flexible and widely supported but it has some drawbacks when it ...
0
votes
0answers
13 views

Merging JSON objects

I have 2 JSON structures. Input: ...
0
votes
0answers
24 views

Three functions to make a JSON array

Currently I'm using these three functions, that in the end produces a JSON array. I went this way so that I could fetch data from a specific table. But now it just seems bloated and poorly written, ...
1
vote
2answers
47 views

Grab photos from Flickr

I wrote the following code for a coding challenge I was given and it received the following criticism: it was quite a beginner attempt using Angular. ...
3
votes
1answer
50 views

Generating jQuery mobile “pages” dynamically

I'm doing a college assignment with jQuery Mobile and JSON. Best practice with jQuery mobile is my main concern. My html starts off with a main 'page' (data-role="page") inside a div with ...
0
votes
0answers
14 views

Flattened Data Model and noSQL data structure

I am currently building a small application using a service which requires and advocates the use of a "flattened" data model (the service is Firebase). As I had no experience with data models before, ...
2
votes
2answers
48 views

Program to edit an address book stored as a JSON file

I was told to come here from Stack Overflow. I'm trying my hand at an address book and the goal is for it to have a bit more of error prevention, for instance for the key "phone" to have 10 digits, ...
0
votes
1answer
52 views

JSON Writer (PHP)

I have written a simple PHP Script that takes $_POST input and uses it to add data to a .json file. Given the security flaws in ...
0
votes
0answers
5 views

Best way to build a JSON API coupled with HTML views in a Rails project [migrated]

I've got a Rails eCommerce project communicating with an iOS app. The iOS app receives JSON data from the Rails back-end, but there's also HTML rendering when a user comes to the project from his ...
0
votes
2answers
70 views

Currency converter in Python 2.7

I'm a beginner and it is my first project in Python 2.7. My goal is writing a script that I can run with two or three arguments. If run with two arguments like ...
5
votes
2answers
85 views

Adding an item to database + JSON

Is this code good? Or is it the noobiest PHP you've ever seen? ...
1
vote
0answers
19 views

Send Google Cloud Messages

I wrote code which is doing query and insert inside while loop. ...
3
votes
1answer
647 views

Wrapper for a transfer transaction API

I'm looking for any kind of advice, like when or where to do exception handling, the overall library structure/layout, usage of classes/partial classes, code efficiency, naming conventions, and so on ...
2
votes
2answers
59 views

Generated serialization code

CGbR project I am currently working on a project that generates code from classes. The idea is to achieve maximum performance by replacing reflection use cases with fast, generated code. Current ...
0
votes
1answer
53 views

Submitting a form via JSON

I have a feedback.js that I would like to improve. ...
4
votes
1answer
28 views

Invoking API calls with parameters specified using JSON

I have an instance of a Java class that I need to call some functions on, using the API exposed by another party. For each call, I need to both check for thrown exceptions, and check the value of the ...
1
vote
0answers
44 views

Transforming a parts catalog into a different data structure

The entire purpose of this code is to arrange the data that was dumped into CommRef_ into the required structure of ResObj. The ...
0
votes
1answer
44 views

Merging JSON objects with common values

I am trying to merge JSON objects which have common values. This is the original JSON: ...
0
votes
1answer
82 views

Wikipedia search using the JSON API

I ask to you. What I could do better in my code or logic? This my example on Codepen -> Wikipedia Search ...
2
votes
1answer
38 views

Regrouping JSON object

I wrote a JavaScript source which regrouping by new key i.e. following JSON to the other: ...
1
vote
1answer
37 views

Twitch client that notifies me when a followed streamer comes online

I've been writing code for a little while but I'm a little slapdash. I'd like to get better so I've been having a glance at best practices, other peoples code and reading a whole lot. I'd appreciate ...
7
votes
3answers
49 views

From Q to compiler in less than 30 seconds

As an adjunct to From new Q to compiler in 30 seconds, I've created a Python script to automatically download the markdown from any question on Code Review and save it to a local file using Unix-style ...
1
vote
1answer
46 views

Nested loop to transform MongoDB results

I have the following structure returned from MongoDB: ...
0
votes
1answer
34 views

Collect several API call results

Want to brush up my rusty web dev skills. I want to call the twitch API for several channels and eventually call a callback function when all results are in without using a sync call. I didn't work ...
1
vote
0answers
74 views

Submitting a JSON [closed]

I have service to which I have to submit a JSON but I have to send the JSON multiple times and the code is slow. How can I improve the performance? ...
0
votes
0answers
116 views

Loading autocomplete text view adapter dynamically using async task in Android

I am working on an app in which I need to get destination list from server and set it in autocomplete text view. I am using text watcher and on its onTextChanged event I am fetching destinations data ...
5
votes
1answer
67 views

Serializing (and deserializing) basic mesh using JSON.net

In order to improve my c# (which is fairly basic at best) I decided to try to serialize a simple mesh to a file using the JSON.net library. Simple mesh in this case means an array of vertices and a ...
4
votes
1answer
93 views

Parsing JSON using jsoncpp

I left questions in the comments strategically, since I think it's easier to answer questions this way. Basically what my small class does is abstracts away functionality that was originally in a ...
0
votes
1answer
130 views

Parsing JSON in one go using state machine solution

I need to parse a simple JSON string (flat JSON, no hierarchy) for keys and values, and there is a system constraint that I cannot use any built-in JSON library and can only read a string once due to ...
1
vote
0answers
33 views

Excel-to-JSON parser 2

After first code review I have fixed the found issues. Could you please review my new refactored application? Main class (entry point) ...
0
votes
1answer
59 views

Excel-to-JSON parser

I just wanted to build a simple converter from an XLS Excel file to JSON. I have predefined JSON format. All fields except of two - are just simple mapping from Excel to JSON. The two fields have a ...
3
votes
1answer
168 views

Newtonsoft Json helper class

I've written the following helper class to help serializing objects to and from Json. I would appreciate some feed back on the style of the class. ...
3
votes
1answer
55 views

Angular JSON weather app

I'm pretty new to Angular. I wrote a weather app and need my code reviewed. I especially need help on best practices for handling edge cases on the response from the JSON endpoint. Here's the HTML: ...
5
votes
2answers
70 views

Tracking Containers in a Train Station

This is a time line for control over the events of some containers in a train station. It gets all the data to build the time line by getting a JSON from a database via REST service. The app resets ...
2
votes
2answers
207 views

Parsing JSON in one go

I need to parse a simple JSON string (flat JSON, no hierarchy) for keys and values, and there is a system constraint that I cannot use any built-in JSON library and can only read a string once due to ...
-1
votes
2answers
91 views

JSON string parsing

I need to parse a simple JSON string (flat JSON, no hierarchy) for keys and values, and there is a system constraint that I cannot use any built-in JSON library and can only read a string once due to ...
0
votes
1answer
22 views

Converting height map bitmap to json

This is my first F# program. It's a command line utility that takes a parameter containing a path to an height map bitmap and prints out this height map converted to JSON format. ...
3
votes
1answer
84 views

GPSD socket connection and decoding JSON into Python dictionaries

GPS3 is a python 2.7-3.5 interface to GPSD. I've stripped back everything to two classes. ...
2
votes
1answer
50 views

Basic JSON Representation in Rust

This week I started reading "The Rust Programming Language". As I reached the chapters on enumerations and pattern matching I felt I had enough material to put together a simple representation of JSON ...
1
vote
0answers
114 views

making dynamic tables with JSON - angular2

Okay, so simple enough task - I'm using Ionic/Angular2 to develop an auditing app. Using angular I can map Objects into the DOM rather easily, so what I need to do is create an object - but I would ...
2
votes
2answers
52 views

RSS to JSON for insertion into MongoDB

In my code, there is a chain of functions call where the deepest function may throw an exception. I catch and handle it according to the business logic. The problem is that all other functions in the ...
1
vote
1answer
53 views

Filters for a JSON collection

I am trying to create a class that parses a JSON and selects all labels, or just a particular label that you prefer to later do a calculation with the value pair extracted off that label. This is ...
4
votes
1answer
44 views

Converts the JSON object to another structure of JSON

I want a JSON object of the following structure to plot a chart ...
6
votes
1answer
74 views

Parse JSON data of upcoming fixtures of Chelsea FC

This program makes a call to an API (http://api.football-data.org/) and obtains data for fixtures of Chelsea FC for the next 100 days in JSON format. The JSON is parsed into a Java object and then ...
2
votes
0answers
37 views

Extracting data for a tag cloud using Lazy.js

I've just started using Lazy.js, which is my first exposure to a "functional style" javascript library. I'm still utterly lost as to which of the hundred different functional javascript libraries to ...
2
votes
2answers
115 views

Minimal CORS mail PHP

I have an PHP endpoint used to mail me feedback or error logs from my sites here: https://github.com/kaihendry/vanilla-php-feedback-form/blob/master/feedback/feedback.php ...
4
votes
2answers
183 views

Tic-Tac-Toe machine learning

I recently started getting into machine learning and I wanted to write a "beginner program" which would learn to play Tic Tac Toe. This code was inspired by a different program I saw, meaning some ...
1
vote
1answer
84 views

Testing a Rails API controller

I'm building a JSON API. I'm writing my controller tests so that they compare the response body to actual JSON I'm generating in my tests using ActiveRecord. I wrote two helper methods that make the ...
1
vote
0answers
27 views

Script to migrate event, artist, and venue information from MongoDB to Drupal

At first I brute forced the migration to just get it finished. However, the procedural program mixed the events with the venues so I rewrote it, this time using classes which I'm just beginning to ...