Contents tagged with Ajax

  • Book Review: "Ajax in Action"

    Let me first preface this review by saying this is the first technical book that I've read cover to cover TWICE prior to posting a review. I had to make sure the stuff stuck, because the material covered in Manning's very excellent "Ajax in Action" is really deep. But bringing the next evolution of user experience, giving your web applications a rich client feel, isn't completely easy. This won't scare you away from using Ajax in your existing applications, but make you aware of exactly what to expect.

    The book first starts out by presenting a healthy discussion of the key components of remote scripting - CSS, the DOM, JavaScript's XmlHttpRequest object and client callbacks - and how they interact within the scope of your project. Before diving into full-on Ajax development, authors Dave Crane and Eric Pascarello discuss the need for object-oriented JavaScript programing, which will be foreign and awkward to most developers, even those coming from procedural backgrounds like Java and C++. The authors familiarize you with the various ways of composing the unconventional constructs available (JSON-RPC, prototypes) for optimizing remote scripting.

    Best practices are encouraged throughout the chapters and enforced in all code snippets. The use of patterns like Observer, Command and MVC and refactoring and module-based programming (mainly .NET assemblies and Java servlets) permeate the entire work. The actual meat of the book doesn't get started until Chapter 9, which the authors clearly state, dealing with the aforementioned discussion of raw JavaScript programming that'll be completely new to most people. But for those not wanting to engage in the massive task of writing syntax by hand, the major libraries available are thankfully referenced.

    The book also isn't a "copyist's" title, one that can provide working code right out of the gate. Also, the audience for this work should be fairly sopisticated and experienced with modern-day web programming, as the book assumes a certain level of competency and doesn't waste time with rudimentary concepts or examples. Crane and Pascarello take a platform-agnostic look at incorporating Ajax-style programming into web applications, citing examples in PHP, Java and .NET, and accordingly the examples are all partial and abstracted, to be implemented in whatever platform the developer/reader is familiar with.

    This is also one of the few books that I've ever recommended people read the appendices in addition to the chapters. Most titles have supplementary info that doesn't match the flow of the chapters, or exclusionary stuff you can skip, but this book is really a tome of good reading. Appendix B is an outstanding discussion on JavaScript OOP, providing an introduction to and examples in JSON.

    Ajax programming is a lot more complex than it lets on, but not as daunting as you might think. This book is critical in your understanding of how to make the next big thing in web development to work for you. A must-have.

    Read more...

  • Manning publishes "what is Ajax?" screencast

    I got an e-mail from Manning Publications about a "screencast" (I'm not sure exactly what that is, but I'm guessing a series of screenshots set against narrated audio) for a "What is Ajax?" presentation.  It's 4 minutes long, so it'll be a nice break while you download today's podcasts or synch your PDA.

    Check it out:
    http://www.manning-sandbox.com/category.jspa?categoryID=229

    Read more...

  • Bravo, Rick Strahl: comments on Ajax's downsides

    I've been asking lots of questions about the potentials of Ajax programming to hurt an app, probing various aspects of the potentials for Ajax-style development to impede on a web app's security, true asynchronous development model, scalability, mobile support, the perception of building faux "rich" clients, and other concerns, many of which admittedly stem from my general ignorance. 

    Read more...

  • Ajax polling/refreshing

    Doing periodic polling in web apps without leaving/reloading a page via Ajax-style programming is something I'm quite excited about.  It'll be cool to have a web page auto-update by way of a VB-esque timer or JavaScript window.setInterval() or other related service when inventory runs out, or a document isn't being edited, or a user logs into the system, or something like that - without post backs, refreshes or redirects.

    Read more...

  • More concerns about Ajax programming as a security risk

    I previously inquired about whether Ajax programming would pose an increased risk for web apps to become compromised or rendered inoperable due to DOS attacks.  I found a link from JamesDam.com about Ajax, and the author (James, assumedly) noted that one of the downsides of his web-based login sample using Ajax was that it increases the opportunity for a brute-force attack.

    Read more...

  • My first Ajax.NET project

    I finally got around to actively using Michael Schwarz's Ajax..NET library for XMLHTTP development with ASP.NET.  It's very easy to use (I actually got confused at how easy it was), and if you can get past the return to hard-coding some of the DHTML elements again.

    Read more...

  • Antacid, anyone? The possibility of Ajax scripting attacks

    Despite my profession, I've never attested to know much about computers, a fact I'll now undoubtedly prove.  I'm wondering if because of the apparently inherent nature of Ajax programming to be a performance concern in executing remote server-side scripts on an per-client-side event basis, potentially firing in rapid succession (which in cases of data access wired up to keypress events can reasonably be a fairly large concern), does this open a dangerous window in the case of form-based data input to injection attacks?

    Read more...

  • Ajax: role in SOA, server load imposition

    There's a bit of a debate going on about whether Ajax can properly co-exist with web services in service-oriented architectures.  Why not?  Michael Meehan's excellent article mentions that while Ajax isn't a great arranged marriage for SOA, they can work very well together (think peanut butter and chocolate).  Others argue that XMLHTTP isn't new and as such serves to be a square peg in modern abstracted, message-centric service development - putting too much emphasis on presentation-layer cosmetics and therefore sitting outside the scope of true SOA.  Also:

    Read more...

  • Other type(s) of asynchronous programming in Ajax?

    Ajax at the moment is gaining a lot of popularity for its ability to make out-of-band calls to remote scripts by way of XMLHTTP that function as server-side handlers wired up to client-side JavaScript events.  This programming model, for the moment with the growing community of samples available on the Web, is used to process relatively small amounts of data, such as simple database queries and other things with minimal payloads to send across the wire. The data is bound to server-side controls and/or DOM objects for display on a page without the waiting of traditional web applications.  This is the essence of Asynchronous JavaScript and XML.

    Read more...