Tagged Questions
0
votes
0answers
35 views
Implementation of dynamical forms for JSON ActiveRecord using JavaScript
I have some data in my database I store as JSON (PostgreSQL supports it). The data can be pretty flexible, something like work-experience, with names of previous companies and positions or education ...
1
vote
0answers
112 views
Populating an HTML table with JSON results
Could anyone suggest a better approach than the one I'm using now? I tried to keep it as minimal as possible, but this is the best I came up with. I did extensive research just to get to this point.
...
2
votes
2answers
60 views
Retrieve data from json file and avoid HTML/JS tight coupling
I am retrieving data from a json object and even though code works I am not sure if I am following best practices.
In particular some of the objects seems too deep (like value.metadata.connections....
3
votes
1answer
102 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 id="all-...
1
vote
2answers
2k views
Fetching data from nested JSON using jQuery and displaying in table
I'm displaying JSON data in a tabular format on a html page using jQuery.
In the function I'm looping the resp.DATA once to get the key names so it can be ...
1
vote
0answers
210 views
Appending JSON values to the DOM
My code below uses JSON to append images into the DOM. It works properly but I want to optimize my JavaScript to see if I can write it in fewer lines or if there are methods I can use that optimize my ...
-1
votes
2answers
4k views
Program that filters JSON data based on user selection
I have made a basic program using AngularJS that displays data from a JSON file, and filters it according to the user's selection (specifically FIFA 15 chemistry cards).
I did plenty of CSS work to ...
3
votes
2answers
82 views
Slurp JSON trading cards to valid HTML
For Cardshifter TCG we pretty frequently update our list of available cards, so I tried to think of a way to make it easy to transform an exported JSON file containing all the cards into a decent HTML ...
1
vote
2answers
55 views
Reloading selects with JSON
My JavaScript code is slow for large inputs. However, it is especially slow in IE. The browser will freeze for about a minute while the select is being reloaded. Any ideas for how to optimize this ...
8
votes
2answers
2k views
Reference implementation of HTML-to-JSON converter for PCG
I have opened a puzzle at Programming Puzzles and Code Golf. The question is not perceived well (yet) and one of the reasons is that no reference implementation is provided. To mitigate this ...
5
votes
2answers
79 views
Command line utility to output modified Markdown
What this command line utility does is to take a text file and update the content a bit before turning it into Markdown. For example, the first for loop searches all the straight quotes and replace ...
6
votes
2answers
10k views
Insert JSON data into rendered template after AJAX call
I have an already rendered template and I want to update it with some JSON data I obtain via AJAX.
The template as it is before rendering looks like this (using ...
2
votes
0answers
109 views
Compressing a blog into a preview using tumblr_api_read
Here is what I have currently working. I would like to make it look more aesthetically pleasing, so not finish words in mid word. Also not have the two previews be so much larger than the other.
...
1
vote
0answers
1k views
Generate HTML from JSON
I have to generate a lot of tables from different JSON files (up to 20 tables per page). Because it's a lot of data, I really want to keep loading speed in mind. I know it's better to use a non jQuery ...
4
votes
2answers
197 views
How can this <ul> be set up to maximize inheritance if additional classes will be passed in from a JSON file?
Objective
Currently I have the flags hardcoded. But want to optimize my code for production. So I am wondering if I have this code done clean enough to leverage CSS inheritance while maintaining ...
5
votes
2answers
8k views
jQuery plugin $(node).toJSON() - convert html form to JS Object
GitHub project repo
I've been working on this little function to convert an HTML form into a JSON Object having the same structure of the form. Basically it is intended to be useful in those ...
3
votes
1answer
9k views
How to exactly work with the JSON Object and jQuery, adding info to posts
I have been working with AJAX and JSON for quite some years now, but to be honest I still do not know exactly what all the functionality are, and how to create optimized code for jQuery.
So my first ...