JavaScript Remote Scripting: An AJAX-based Random Code Generator in Action
(Page 1 of 6 )
In this article, Alejandro Gervasio finishes his discussion of creating a random code generator. Going beyond the core functions, he defines the remaining JavaScript functions needed to turn the random code generator into a functional program.
Welcome to part five of the series “JavaScript Remote Scripting.” As you probably know, this series goes through the implementation of different methods for working with JavaScript-based remote scripting, explaining its advantages and drawbacks, as well as demonstrating several examples, useful for integrating within existing web-based applications.
Stepping back to the previous tutorial of this series, I explained the basics for developing a random code generator, in conjunction with its application in a concrete case: an article-rating system. With reference to this mechanism to generating server-side random challenge values, I’ve gone as far as setting up some core functions, aimed specifically at sending GET http requests in the background, as well as checking for their progress after they’ve been sent out.
In an attempt to provide you with additional information about how the code generator works, I illustrated its functionality by showing some screenshots, together with the corresponding structural (X)HTML markup, to which the system will be applied. Hopefully these extra features will give you a clear idea of how this protecting application can be used in different scenarios.
Now that I’ve refreshed the concepts explained through the previous part, it’s time to move forward to defining the remaining JavaScript functions that compose the application, in order to turn the random code generator into a functional program. So, let’s get started.
Next: Looking at existing functions: the “sendRequest()” and “stateChecker()” functions at a glance >>
More JavaScript Articles
More By Alejandro Gervasio