Slashdot Mirror


Mastering Ajax Websites

An anonymous reader writes to tell us that IBM DeveloperWorks has an interesting article introducing the uninitiated to the world of Ajax. From the article: "Ajax, which consists of HTML, JavaScript technology, DHTML, and DOM, is an approach that helps you transform clunky Web interfaces into interactive Ajax applications. The author, an Ajax expert, demonstrates how these technologies work together. Ajax is more than just the latest fad -- it's your stepping stone to build better Web sites through efficient use of your time."

13 of 307 comments (clear)

  1. Ever notice . . . by Ph33r+th3+g(O)at · · Score: 5, Insightful

    . . . how when a new fad comes along, people say it's not a fad?

    --
    I too have felt the cold finger of injustice.
    1. Re:Ever notice . . . by ceejayoz · · Score: 5, Insightful

      Sure, but when something useful comes along, people say it is a fad.

      Look at what Google Maps did for online mapping and tell me AJAX is "just a fad".

    2. Re:Ever notice . . . by phoenix.bam! · · Score: 4, Insightful

      Ajax is a fad and it isn't. All the hype about it is of course, generated because it's the awesome new fad. But it is an incredibly useful tool. Digg.com does a great job of using AJAX the proper, no intrusive way. GMAIL too. It's great for some things and won't be going away soon. But soon there won't be 20 stories a week posted about it.

    3. Re:Ever notice . . . by m50d · · Score: 4, Insightful

      Web applications shouldn't exist. It's as simple as that. They're an attempt to shoehorn the web into something very different to what it was designed for - it's meant as a documents platform, not an applications platform. If you want to run remote applications, there are plenty of ways to do so - X11 is the obvious one. If you feel it's inadequate for the higher-latency environment of the internet, you're probably right - but the solution to that is not to try and get http to do applications, it's to write a new protocol for doing internet applications. That's what we should have - a new, standard way of doing applications over the internet, designed for doing applications over the internet, and optimized for this task.

      --
      I am trolling
  2. Good but bad! by ech00ne · · Score: 5, Insightful

    AJAX doesn't make it easy to develop cross-platform web applications. Look at all the browser incompatibilities in the developing of Gmail and more recently MSN's start.com page.

    We need to re-standarize Javascript or at least make sure all the browsers implement a 100% compatible version. And I don't think that will work since not even HTML is properly rendered by any browser at all.

    1. Re:Good but bad! by _Neurotic · · Score: 3, Insightful

      It's not so much a matter of making each browser's implementation of JavaScript compatible. The real issue is their differing object models. The object models are a direct result of their respective design methodologies and approaches to security. There any many similarities (like the top level window and document objects) but when you get down to the nitty gritty (a must for "AJAX") you are bound to run into the differences that require conditional logic to provide cross platform compatibility.

      So, unless we end up with one web browser, we'll never have a common object model and will therefore always have incompatibilities.

  3. Best thing since sliced bread! by abelikoff · · Score: 3, Insightful
    AJAX...helps you transform clunky Web interfaces into interactive Ajax applications.

    Recalling the Simpsons: "Only suckers buy [last year's] model. You are not a sucker, are you?"

    I can't wait to start padding my resume with the latest and greates technology out there that will do the same thing we've been doing for decade but with more acronyms and steeper learning curve.

  4. Re:Ajax in action by junjun26 · · Score: 3, Insightful

    That's why it works so much better for web applications than normal web pages. Why would you bookmark a page in your Gmail account ;)

  5. Re:Ajax in action by Bogtha · · Score: 4, Insightful

    That's not Ajax, that's developers who have screwed up. You can have Ajax and addressability (bookmarks, back button, etc) for 99% of the things Ajax is good for. It's just you have all these newbie web designers jumping on Ajax like there's no tomorrow, so most of the things you see have had lots of shortcuts taken, and some of the things you see shouldn't have used Ajax in the first place.

    A good rule of thumb for knowing when it's appropriate to use Ajax is where you intend on posting something to the server, and then redisplaying the page you just came from. For example, Slashdot's moderation. It makes no sense to regenerate the entire page just to tell the server what you think of one particular comment. This is also the situation where bookmarks, the back button, etc aren't going to break.

    --
    Bogtha Bogtha Bogtha
  6. Re:When is AJAX appropriate? by Bogtha · · Score: 3, Insightful

    You don't need polish to keep users, you only need polish to attract users. Take Slashdot as an example. Hideous design, atrocious implementation, no polish whatsoever, full of bugs, and yet people keep coming back to it.

    Once you've attracted users, they rarely go away unless you give them a push (like endlessly posting repetitive articles on Ajax, for example).

    --
    Bogtha Bogtha Bogtha
  7. Re:When is AJAX appropriate? by heinousjay · · Score: 3, Insightful

    You're almost there, but the number of users has nothing to do with it. You use it when it's appropriate to support a desktopish interaction model, and you don't want to reload the page every time.

    Also, I'd clean up the terminology. You don't use it for web sites. You use it for applications.

    --
    Slashdot - where whining about luck is the new way to make the world you want.
  8. Re:JavaScript code is the core code - What??? by KiloByte · · Score: 3, Insightful

    Also, if you consider the popularity of the "NoScript" extension, you'll see that a lot of people turn JavaScript off. Having it permanently disabled is a part of many security policies, as well; I would estimate that at least 10% or so of people will have JavaScript disabled at least on their first visit. This is a lot more than a minority such as "Links users" or "the blind".

    So... unless you disregard a significant percentage of viewers, you do need to provide an alternate version.

    The article says: "Ajax is more than just the latest fad -- it's your stepping stone to build better Web sites through efficient use of your time." -- tell me how can AJAX save you time if you have to do _both_ versions of the site, multiplied by the number of differently behaving browsers?

    --
    The creatures outside looked from Alt-Right to Antifa; but already it was impossible to say which was which.
  9. Re:Ajax in action by Geoffreyerffoeg · · Score: 4, Insightful

    A good rule of thumb for knowing when it's appropriate to use Ajax is where you intend on posting something to the server, and then redisplaying the page you just came from.

    Completely. AJAX should only be used when you would've POSTed something to the server and made a slight change - both of those are non-bookmarkable and non-addressable. (Good) web designers seem used to when to GET and when to POST, so only use AJAX in the latter case. The general rule for that, by the way, is that POST should change stuff on the server, and GET should only retrieve data. Thus, you can only bookmark a view of data, not a change of it - you've already changed it once you're ready to bookmark.

    AJAX can actually help with the entire problem of tabs and forms - if the form only changes data but doesn't update the view, you can use a regular link to see a different view of it.

    The other solution is to do what Google Maps does - since they're using AJAX to retrieve views, they have a button called "Link to this view" or something that gives you a context-free URI to that particular view.