AJAX (Asynchronous Javascript And XML) is a popular technique for creating interactive websites, allowing web content to be updated asynchronously by exchanging small amounts of data with the server behind the scenes.
-4
votes
0answers
14 views
Casading dropdowns with preselect values in MVC [on hold]
I have a requirement of cascading 3 dropdowns in MVC which are interrelated to each other. I am using Chosen plugin of JQuery.
First dropdown is auto filled from controller, 2nd dropdown is filled on ...
-5
votes
0answers
12 views
0
votes
1answer
41 views
Displaying weather data from an Arduino
Please review my code, for performance and readability.
3 issues I am facing are
Uncaught Exception : out of memory (in firefox)
randomly Failed to load resource: The request timed out.
Even if the ...
0
votes
0answers
63 views
Ajax Validation Handler
I'm trying to transition my app from a collection of server scripts to something that uses SOLID concepts.
I'm stuck trying to figure out a better way to do ajax validation.
I currently have a file ...
3
votes
0answers
45 views
Passing a complex object across cross domain
I am working with two web applications, one is webform-based Site1 and other is an MVC application Site2.
TODO:
Pass a complex object from Site1 to Site2. In response get View from Site2 to Site1 ...
0
votes
0answers
59 views
Zend Framework 3 Ajax Form Validation - contact form
I would like to present to you my code vision of Ajax form validation in Zend Framework 3. I am a beginner in Zend Framework and jQuery too, so I don't know that my solution is good and acceptable.
...
0
votes
1answer
219 views
Simple JavaScript quiz app using an external questions.json file
I have a quiz app that gets data from a questions.json file using AJAX, loads them into my script file, and then use Handlebars to compile templates so I don't have ...
1
vote
0answers
38 views
Simple XmlHttpRequest to be used with web workers
I have a very basic XMLHttpRequest function that would be used with web workers.
I would like to know how I could improve it to handle possible errors better:
...
3
votes
1answer
30 views
Take a search term and return a list of location from an API
I've just refactored some code for a search box which takes a user search term, hits an API, returns a list of possible locations, and processes the users chosen result by sending them to a map page ...
3
votes
0answers
98 views
ASP.NET MVC - server-side Ajax result conversion
I am currently in the process of creating a website which requires it to work with and without JavaScript enabled. All callbacks to the server with JavaScript enabled will be made through Ajax ...
1
vote
2answers
22 views
Updating a Drupal web page with content based on inputted text
The intent is to update an existing Drupal web page with content based on text entered into a textbox.
The existing page displays data from a database in a table. This code gets JSON formatted data, ...
2
votes
1answer
61 views
Synchronising data with AJAX calls
I'm developing a mobile app with Cordova, jQuery and jQuery mobile. To synchronise the data saved on a device I make AJAX calls to a server (I'm sending and ...
2
votes
1answer
74 views
Registration form validation in jQuery
I have created a registration form using jQuery. I am validating username and password using an AJAX request. The "submit" button is originally disabled and is only enabled when all three fields of ...
0
votes
1answer
62 views
JavaScript multiple ajax calls but can either be one or two
I'm writing a piece of JavaScript to make one or two ajax calls. There will always be one ajax call fired but it might be two based on cookie setting. If user is logged in then we call another service ...
1
vote
2answers
98 views
4
votes
0answers
110 views
React component to list TV shows from a JSON result
I'm trying to rewrite my old project in Reactjs. As I am a beginner and this is my first app, I need some assistance in understanding what is the best way to do this in the React way and how I can ...
2
votes
1answer
76 views
File extension detection and restriction on upload
I am trying to build a multiple file uploader with jQuery and Ajax. I would like to know how this code could be improved. I feel the client side validation of file types in my code are presently not ...
1
vote
1answer
132 views
Load page content on hashchange
I want to create a modular website with no frameworks or CMS nor server-side language.
Also, I am doing simple use of the hashchange event to help the navigation.
The structure would be as follows:
...
1
vote
0answers
31 views
AJAX Form Creator
I wrote an AJAX Form Creator (in the form of an js object constructor) that takes a form and a callback. I am a decent, slightly okay, completely novice developer, and could use feedback on coding ...
5
votes
1answer
623 views
Random quote generator from API
I have built a random machine generator website. It fetches the quotes from forismatic and has a button to get a new quote. When it gets a new quote, the website color changes. It also features a ...
0
votes
0answers
274 views
Polymer decorator to make iron-forms actually work
I just finished writing a first version of hot-form. It's a simple decorator that makes iron-forms do I basically always do:
Show error messages, or a custom ...
7
votes
1answer
154 views
Make Simultaneous HTTP Requests That Resolve Into a Single Return
This week, in an ongoing job search, I was tasked with the following pre-screening question:
Make two simultaneous http requests. Use the language and library of your choice. Make sure the results ...
7
votes
2answers
173 views
Simple inbox functionality using JavaScript and Ajax
I've been developing a simple CMS both for practical use and learning about Laravel, and I decided to implement a simple service that makes it possible for the administrators to send messages to one ...
0
votes
1answer
42 views
Accessing Models Directly Through AJAX [closed]
I was thinking about how to handle AJAX requests in a MVC environment in PHP in a easy way.
What I've come up is (without showing you the backend code):
...
3
votes
1answer
82 views
PHP & AJAX CAESAR CIPHER ENCRYPTED chat script - Slow in performance
I have made an attempt to make a chat script and its working as required but the problem is that it is slow on slower connections and sometimes even on fast connections. Sometimes while loading the ...
4
votes
0answers
112 views
Colour-matching game
This is a game about matching the right colour. In the first level you start with 3 cubes that each have a different colour. After 2 seconds the colours of the cubes disappear and the cubes become ...
2
votes
1answer
85 views
Loading an animation with an Ajax request
I am not sure if this is the correct way to make an Ajax request and do the typical loading/processing GIF/animation while processing is happening and displaying the response.
HTML:
...
0
votes
0answers
238 views
Php Ajax script to check server status of sites from db
I am writing a script for a client so hey can check the status of their servers.
The script performs ajax requests to get the data as json then poulates the table with the returned json results.
is ...
2
votes
1answer
77 views
Cross browser JavaScript implementation of xhr
I wrote a small, cross browser compliant implementation of xhr requests in client JavaScript that closely follows the jQuery $.ajax() API and standards. The goal is ...
2
votes
1answer
366 views
Session expiration handler using PHP and jQuery
At this point i am interested to see other techniques on handling session timeouts.
What are some good improvements on this script to detect when a session is no longer valid?
Important definitions:
...
1
vote
1answer
35 views
Making a news widget webpage
I have finished the assignment but would love some feedback. Data.json contains news articles data.
Requirements for assignment:
Fetch the data and render it on the page. Initially the page ...
0
votes
1answer
71 views
2
votes
0answers
32 views
JavaScript AJAX page flipper
I rarely see this kind of navigating on the web. But basically I load all the content in the background and then flip pages as needed while loading user specific data via ajax.
Are there any ...
0
votes
1answer
461 views
Wikipedia search using the JSON API
What could I do better in my code or logic?
Wikipedia Search
...
3
votes
1answer
48 views
Place Ajax request on completion of Ajax Request
I have an Ajax request which in turn on completion make another Ajax request:
...
4
votes
3answers
1k views
A reusable AJAX polling function
I have written a small JavaScript function which performs an AJAX request every x seconds.
I was hoping some of you could give it a look over and give me any pointers on redundant code or bad ...
6
votes
3answers
60 views
Navigation script and template
Overview:
I'm using the following page template and scripts for navigation. I use a single page that loads menus and context content, and then use ajax or GET variable to load main-div's content, by ...
2
votes
0answers
55 views
Ajax login response [closed]
I want to create an Ajax-Login, but I'm not sure if my solutions is generally correct. I want to do everything correct, so I need someone who checks this code and give me some improvement hints.
<...
2
votes
2answers
92 views
JavaScript Payload
I am coding a proof of concept on the danger of JavaScript poisoning, XSS and other client side attacks.
Therefore, I coded some JavaScript payloads. As I am not very familiar with JavaScript (I ...
0
votes
0answers
25 views
Extracting articles mentioned in comments in three GET requests
I need to make several HTTP GET requests and do the following stuff:
When all of them will be completed, I need to parse each HTML
After HTML parsing or in case of any error I need to set flag ...
0
votes
0answers
17 views
Processing the results of several GET requests via jQuery
I need to make several HTTP GET requests and do the following stuff:
When all of them will be completed, I need to parse each HTML
After HTML parsing or in case of any error I need to set flag ...
1
vote
1answer
41 views
Displaying available destinations using Angular.JS
I wonder to know if there is any bad smell on my practice for i18n on Angular.
I put the I18n translating function on Angular controller (because I don't know how to put it on HTML template file)
And ...
4
votes
1answer
62 views
Controller for a vehicle servicing AJAX app
I am working on a codebase that operates in the following manner:
...
3
votes
2answers
290 views
Large table updates using AJAX in Internet Explorer 11
I have a website which only needs to support IE11. It is a single page application, which has about 200 table rows and each table row has 5 child rows.
There is a pulsing function that updates the ...
0
votes
1answer
596 views
Creating a wrapper function for jQuery Ajax
I am creating a few functions that wrap around jQuery's Ajax function to make it a bit quicker and easier to perform a request. For this I have this JavaScript file:
...
0
votes
1answer
188 views
Functional Javascript Practice with AJAX
I am currently doing projects in freecodecamp.com to brush up on my javascript skills and just finished a weather report widget. It does the following:
Gets api ...
4
votes
1answer
37 views
Three identical AJAX button handlers in three views
In my Rails 4 app I have this event listener:
...
0
votes
1answer
95 views
HTML template for win-loss data in Javascript with Mustache
Can anyone suggest a better way to implement my template code?
...
2
votes
1answer
94 views
Creating a login page
I have created a test login page that, as most do, takes in two values from the user (username and password) and the processes it.
For this I have opted to use jQuery and AJAX to pass the results to ...
0
votes
2answers
86 views
Ajax request URL with the Google Maps API
I am making an HTTP request with the Google Maps API and I have to pass in parameters (adresses/coordinates):
...