Slashdot Mirror


Cutting Through the Ajax Hype

An anonymous reader writes "If you're thinking about building an Ajax application of your own, this article would be a good place to start. It's an introductory-level guide about when and how to implement Ajax. It provides a balanced discussion about where exactly using Ajax makes sense, and where it does not."

48 of 77 comments (clear)

  1. Isn't it sort of saddening... by urbanradar · · Score: 3, Interesting

    ...how much time passed in between stories about said AJAX hype hitting Slashdot and stories about "Cutting through the AJAX hype" hitting Slashdot?

  2. Ajax Hype by John+Sokol · · Score: 3, Interesting

    Oh man, I had written a chat room in back 1996 using what I called server push Java Script and nobody paid much attention, although it was on many adult video chat sites. Example at http://www.videotechnology.com/chatroom.html

        We did many of the same things using that technique that people are doing now in Ajax, interactive games, and database etc using it.

      Suddenly some marketing guy calls it "Ajax", which is almost doing the same thing is all the rage.

    --
    I am always doing that which I can not do, in order that I may learn how to do it. - Pablo Picasso
    1. Re:Ajax Hype by Shados · · Score: 1

      10 years ago, the market was different. Plugins weren't shunned as much, keeping things lightweight wasn't as important (in the mind of developers...as its probably LESS important today, with the powerful machines we have and all), etc.

      Now in this day and age, things like java applets and Flash get shoved aside, even if it actualy DOES make sense to use them in a given situation. Thus people being all over ajax.

    2. Re:Ajax Hype by complete+loony · · Score: 1
      Heck I made a P2P presence system for the office using a Java applet, multicast packets, Javascript and DHTML some time around 2000. And that didn't have any server code at all.

      This stuff isn't rocket surgery.

      --
      09F91102 no, 455FE104 nope, F190A1E8 uh-uh, 7A5F8A09 that's not it, C87294CE no. Ah! 452F6E403CDF10714E41DFAA257D313F.
    3. Re:Ajax Hype by dheera · · Score: 1

      Back then you could also accomplish this "Ajax" BS by just creating an IFRAME in your page and accessing its contents from its parent frame. It was nice and handy. I used it for a long time on webpages, until somebody figured out that you could use it to read contents from your visitor's hard drive too, resulting in the "bug" being corrected.

      After that, so long as your content was rectangular, you could just use the IFRAME itself to accomplish the same effect as what Google does today with "Ajax" in a table.

      Nothing new at all.

    4. Re:Ajax Hype by illuminatedwax · · Score: 1

      If Javascript had any documentation, everyone would have been using it that early as well.

      --
      Did you ever notice that *nix doesn't even cover Linux?
    5. Re:Ajax Hype by Anonymous Coward · · Score: 1, Insightful

      Plug-ins are often "shoved aside" so that the application will run in some of the strict corporate IT environments. A bunch of our customers (mostly banks) don't allow any plug-ins installed on their users' machines. We'd love to use flash instead of AJAX, but we're forced to use only features of the core browser.

    6. Re:Ajax Hype by mattwarden · · Score: 1

      Lots of people were doing this. But there are a lot of factors that make it "all the rage", the least of which is the marketing term.

    7. Re:Ajax Hype by AaronLawrence · · Score: 1

      That must be terrible. Forced to use those desperately restricted web browsers for banking applications. How can they manipulate their 3D bargraphs?

      --
      For every expert, there is an equal and opposite expert. - Arthur C. Clarke
    8. Re:Ajax Hype by AKAImBatman · · Score: 1
      Back then you could also accomplish this "Ajax" BS by just creating an IFRAME in your page and accessing its contents from its parent frame.

      Except that it didn't work in Netscape 4.x. Which was the big reason why it didn't take off back then.

      (Yes, I pulled the IFrame trickery several times as well.)
    9. Re:Ajax Hype by Tablizer · · Score: 1

      Oh man, I had written a chat room in back 1996 using what I called server push Java Script and nobody paid much attention...

      1996? JavaScript was barely out and buggy and crashy up the wazoo.

    10. Re:Ajax Hype by SQL+Error · · Score: 1

      I was doing this for an in-house app in 1998, and even then it would lock your browser up (or just plain crash it) after a few hours.

      One of the major reasons AJAX is having success now is that it actually works - now.

    11. Re:Ajax Hype by John+Sokol · · Score: 1

      >1996? JavaScript was barely out and buggy and crashy up the wazoo.

      Yes it was. But we had it working fairly reliably overall. This was also working with my livecam server push jpeg video.

        www.livecamserver.com

        What's amazing is Microsoft deliberatly went out of there way to break the X-mixed-multipart we were using to get MS IE to play the video.

      --
      I am always doing that which I can not do, in order that I may learn how to do it. - Pablo Picasso
  3. This article is moot by Timesprout · · Score: 2, Insightful

    Now that Google has released GWT as open source. All the fanbois will rush to ajaxify their sites regardless of requirements, creating even greater mostrocities while all the time laughing at sites which are not sufficiently 'ajaxy'.

    Then XAML and XUL will see greater adoption for rich client development and we return to the days when ajax was just a household cleaner.

    --
    Do not try to read the dupe, thats impossible. Instead, only try to realize the truth
    What truth?
    There is no dupe
    1. Re:This article is moot by not+already+in+use · · Score: 1

      Yeah, haha, you're so right. I can't wait to revert to the days of "This site is viewable only in IE" or "This site is viewable only in Mozilla Firefox." God damn google, their open-sourcing bullshit, and the adoption of a tool kit that allows cleanly written ajax applications that are widely available on different browsers, hell even many legacy browsers. This isn't what we need right now. We need applications written using technology that is still years away from mass adoption! And of course, anyone who could be labeled a "fanboi" (you're clearly a fan of avril lavigne) would be smart enough to pick up java and convert their backend to servlets on the $5 a month LAMP packages without tomcat.

      --
      Similes are like metaphors
    2. Re:This article is moot by maxume · · Score: 1

      Ajax is all about transport, xaml and xul are mostly about widgets and layout. Much ongoing use of XMLHttpRequestObject(ajax without the buzz...) is to transfer json; why? because it is straightforward and tends to 'just work', without 'silly' overhead. Xaml and xul might offer local storage/caching, I don't know, but xaml and xul are to xml/html, not ajax.

      --
      Nerd rage is the funniest rage.
    3. Re:This article is moot by Scrameustache · · Score: 4, Insightful

      the days when ajax was just a household cleaner. *mumble*hero of the battle of Troy*mumble*
      --

      You can't take the sky from me...

    4. Re:This article is moot by SanityInAnarchy · · Score: 1

      True enough, but it always seemed to me that the biggest problems of AJAX was the HTML. Browser hacks, performance implications of quirks mode, browser hacks, performance implications of generating HTML from JavaScript and then parsing it for no good reason, and browser hacks.

      I'd like to see the JavaScript go away, but it's at least theoretically possible to build an efficient JavaScript compiler/interpreter, and it is a damned powerful language. The problem is, HTML was designed to mark up web pages. It makes perfect sense when you're mostly using it for the hypertext effect -- just the occasional <a href>, or using <b> and <i> to essentially develop a page the way you'd do a word processing document.

      It has no place in actual application development.

      --
      Don't thank God, thank a doctor!
    5. Re:This article is moot by Tablizer · · Score: 1

      Now that Google has released GWT as open source. All the fanbois will rush to ajaxify their sites regardless of requirements, creating even greater mostrocities...

      Good. It will take their mind off of trying to use every GOF OOP pattern in the book just for the hell of it.

    6. Re:This article is moot by G-funk · · Score: 1

      There is no AJAX, only XUL!

      --
      Send lawyers, guns, and money!
    7. Re:This article is moot by blafasel · · Score: 1

      *mumble* _TWO_ heroes of the battle of Troy*mumble*

      --

      check your speling
    8. Re:This article is moot by phaggood · · Score: 1

      >Yeah, haha, you're so right. I can't wait to revert to the days of "This site is viewable only in IE"

      Tell me about it. I had to help my dad get some pics off of an MLS site for realtors (he's in real estate) and it said 'IE' only. I had to hit refresh a few times because I didn't believe it; what year is this?!?!

  4. Too Sloanie by dheera · · Score: 1

    "Ajax" is just another hype word. It's like how management types run around their companies saying BS like: "employ XML" "facilitate collaboration" "empowering innovators" "strategic thinkers" blah blah blah. it's so much crap. "HTML" was something new. It DID stuff. You wrote and you SAW it on the screen. "JavaScript" was something new. It did all kinds of stuff to make webpages dynamic and functional in new ways. "DHTML" is a craptastic synonym of "HTML with JavaScript" "XML" is utter crap. Try double-clicking a .xml file on your computer and see if anything happens. Then try double-clicking a .html file and tell me which got you to information faster. Don't tell me XML is some revolutionary standard BS, it's like saying "we redefined the .ini" file. For god's sake shut up about XML being anything new. It doesn't do anything. "Ajax" is another crap term. It's management majors realizing after so long that "WHAA! We have XMLHttpRequest in our JavaScript specification? WOW! WOW WOW WOW we have to come up with a new name for it! It's so great we can't just call it JavaScript!" argh.

    1. Re:Too Sloanie by dheera · · Score: 1

      And by that I was not saying I hate "Ajax". It's a cool technology, just a stupid name. It's just JavaScript, nothing ever changed. Sites accomplished the same effect for years using IFRAME's, and JavaScript just came out with a nice handy function to simplify things. It's called JavaScript, dummies. JavaScript. Not "Ajax".

      Don't tell me tomorrow that you're going to realize that JavaScript has a window resizing feature, say "wow wow wow" again, and decide as a management guy that it has to be called "Awacs" (Asynchronous Window Annoying Changing System). It's called JavaScript, dummy.

    2. Re:Too Sloanie by Hawkxor · · Score: 1

      you do realize "Sloanie" doesn't make any sense outside of cambridge right?

    3. Re:Too Sloanie by dheera · · Score: 1

      yes, but at least there's a good deal of readership from there :-P

  5. Hypes by El+Lobo · · Score: 1, Interesting
    Once every2-3 years it seems like "the new big thing" is hyped. Call it Java, ASP, php, Ajax... The enterprise world is then ready to show you that the curent hype is the Holy Grail and the best thing since a cold beer.

    Ajax is getting hyped to the point where it isn't funny anymore. I bet it will go the way of XML - simple and interesting at first, then the "Enterprise" folk run away with it and within 2 years we have W3C AJAX standards that span 1000 pages. Wanna bet?

    --
    It's time to realise that Abble's products are the biggest abomination these days. Just say NO to the dumb iAbble way!!
  6. Ajax is no easy substitute for good design by EraserMouseMan · · Score: 4, Insightful

    The thing that made AJAX catch on is that a few of the very first notable web apps were very heavy on graphic design and well-thought-out layout.

    So now everybody thinks that if their website can just be written with AJAX technology it will automatically come with a smooth, user-friendly and beautiful interface.

    AJAX is just one technique. You still need to be highly skilled at all the other web-coding disciplines else to end up with a great web app.

  7. Re:Look who's talking by Nasarius · · Score: 1

    It's the system. They really need to work out a better way of displaying threads where the first post is hidden.

    --
    LOAD "SIG",8,1
  8. It Makes Sense by dteichman2 · · Score: 1

    AJAX makes sense wherever the app should be interactive or realtime (relating to server-side data). Keep in mind, that a non-AJAX, plain HTML version should be kept as an option for all users.

    --


    Silence is golden... and duct tape is silver.
    1. Re:It Makes Sense by mattwarden · · Score: 1

      When AJAX is most useful and appropriate, offering a plain HTML option is not useful and potentially impossible.

  9. Cutting through the ajax hype-hype by not+already+in+use · · Score: 2, Interesting

    Whenever a great technology comes about (or in this case a fusion of existing technologies) you always have the people who gotta play devils advocate, you know, the guy nobody likes to hang out with because he's negative about everything. Here's one of my favorite parts FTA:

    "Last month, I was on my way to visit a friend. It was dark and I got lost, and I tried to find his address in my computer. His coordinates were included in the e-mail he sent me that day. Unluckily for me, that e-mail message was sent to my GMail account, and, being disconnected from the Internet, I was left with quite a negative experience. In one split second, all the benefits of zero-install, a cool UI, labels, free targeted advertisements, an extremely useful search engine, and platform independence were annihilated when I could not find my friend's address because I was out of range of a Wi-Fi hotspot."

    GOD DAMN YOU AJAX, CLEARLY YOU HAVE NO COMPASSION FOR THE ILL-PREPARED!! This would have never happened had you been using a non-ajax internet mail application, or even GMail's HTML only version. Ajax isn't only overhyped, it's out to get you. Here's another great snippet:

    "JavaScript applications run in a browser, and can be easily reengineered. By loading JavaScript files on demand, you can fool Internet Explorer users; but other browsers, such as Firefox, will eagerly show a user the current DOM in its entirety through the context menu's View Selection Source option. If someone really wants to see your application's entire JavaScript source and analyze it, a simple script built with the Mozilla® Greasemonkey extension, a debugger like Venkman, or a custom Internet Explorer toolbar would do the trick."

    Yes folks, he is correct here. Ever since ajax has come about, all the sudden your javascript and DOM is viewable to anyone with enough inclination to do the digging. Before "Asynchronous" and "and XML" came along, this certainly wasn't the case, I liked the good ol' days when it was just "J."

    I could go on and about the evils of ajax, but what I would really like to point out, as this guy already has, is that the heart of this evil scourge is the internet itself. Never mind the fact that any 16 year-old girl going to meet a sexual predator on mySpace has the capacity to print a map out before hand because clearly, the intarweb will no longer be available once she has departed on her journey. But thats beside the point. Uninstall your browsers immediatly.

    --
    Similes are like metaphors
  10. Re:AJAX's hatred of the middle-click. by Bogtha · · Score: 3, Informative

    With Firefox and Opera, one is able to open a link in a new tab by middle clicking on it. But unfortunately, many AJAX-enabled Web apps disallow such functionality, for whatever reason.

    It's not Ajax per se that disallows it. The problem is that a lot of developers use <a href="#" onclick="..."> and don't provide an actual URI to open.

    GMail is a major culprit.

    Yes, it is, and I've said as much in the past. It's actually even worse than the average clueless developer, because it doesn't even use <a> for links - it uses <span> and click handlers to provide really, really crappy emulated links. Of course, doing so immediately throws the normal link handling your web browser provides out the window, including (but not limited to) opening them in new tabs or windows.

    Basically every AJAX site I've tried has interfered some way with traditional ways of browsing. I don't know if it's an inherent limitation with AJAX

    It's not. It's usually either developer ignorance or developer apathy - they either don't know how to do it or they don't care.

    --
    Bogtha Bogtha Bogtha
  11. The Answer is a Framework by Chabil+Ha' · · Score: 1

    Frameworks help decouple a lot of things. For example, instead of using M$ 'Atlas' Ajax framework which is not only a bugger to use but introduces a lot of unnecessary coupling, I use Anthem.NET. It takes the existing ASP.NET form tags and extends them. This produces 3 net effects: 1) I don't have to do the crap load of mundane javascript coding (Anthem.Net takes care of that), 2) Should javascript functionality be disabled on the client, the form objects revert back to their regular POST behavior (because of inheritance), and 3) Should I wish to strip out my AJAX functionality there are a lot less dependencies in my code.

    If you go the Atlas route, you're looking for a load of trouble in any of those three scenarios.

    --
    We're all hypocrites. We all have hidden parts, it's the contrast between them that make us more a hypocrite than others
    1. Re:The Answer is a Framework by Shados · · Score: 2, Informative

      Hmm...did I miss something? While Atlas does add quite a bit of features, if you're sticking to ajax functionalities, 1, 2, and 3 are handled quite gracefully... For example, my sites that use Atlas's ajax functionalities degrade perfectly to normal post behaviors if javascript is disabled.

  12. FINALLY by phantomcircuit · · Score: 1

    Finally something telling people when NOT to use ajax....

  13. Re:Look who's talking by tepples · · Score: 1

    They really need to work out a better way of displaying threads where the first post is hidden.

    They already did, and it's called the quote button. If what you quote doesn't match the text it appears you're replying to, then readers will know that there's a hidden post in between.

  14. Is this relevant? by romit_icarus · · Score: 2, Insightful
    Last month, I was on my way to visit a friend. It was dark and I got lost, and I tried to find his address in my computer. His coordinates were included in the e-mail he sent me that day. Unluckily for me, that e-mail message was sent to my GMail account, and, being disconnected from the Internet, I was left with quite a negative experience. In one split second, all the benefits of zero-install, a cool UI, labels, free targeted advertisements, an extremely useful search engine, and platform independence were annihilated when I could not find my friend's address because I was out of range of a Wi-Fi hotspot.

    No - you couldn't find your address because you were stupid enough not to jot it down on a piece of paper when you had the chance. Seriously, blaming GMail for not being able to access data locally is asking a bit too much of the Internet, le talone of Ajax!

    1. Re:Is this relevant? by BritneySP2 · · Score: 1
      stupid enough not to jot it down on a piece of paper

      Paper? Why use paper when you have a computer. Just wondering. Unless, it's a toilet paper, of course - nothing can replace that.

  15. Why does it have to be inline? by SanityInAnarchy · · Score: 1

    Couldn't you just do a frameset with no borders and a single frame of 0 px?

    --
    Don't thank God, thank a doctor!
    1. Re:Why does it have to be inline? by AKAImBatman · · Score: 1
      Couldn't you just do a frameset with no borders and a single frame of 0 px?

      Not really. Netscape 4 couldn't make any changes to the document once it was rendered. Later versions allowed for some colors to be dynamically swapped, and for objects to be resized to reflow the page. But you couldn't actually add or subtract any information.

      In my case, I had used the IFrame to show a list of selected items as the user checked them. The user could page through different weeks on a calendar, so it was important to tell them which dates they'd already selected. The data had to be inlined (according to the specs I was given; and not allowed to change) so I used an IFrame to do both the server upload and the display. There was some alternate logic in Netscape that would refresh the page instead.
  16. Rich Client Demand by Tablizer · · Score: 1

    Once every2-3 years it seems like "the new big thing" is hyped. Call it Java, ASP, php, Ajax... The enterprise world is then ready to show you that the curent hype is the Holy Grail and the best thing since a cold beer. Ajax is getting hyped to the point where it isn't funny anymore.

    Part of it is driven by the desire to have "rich GUI" apps that work like and have the features of desktop app GUI's. The world is wanting. Wether AJAX can deliver that or not is another matter. Getting HTML to act like a desktop is like trying to lick your own a$$.

  17. Re:google web toolkit by Dan+Farina · · Score: 1

    And I would argue ZK is (while different) much more useful to me personally.

  18. w/o java? by remmelt · · Score: 1

    We don't have or want a Java back end. That would pretty much rule out either ZK or the GWT. right? What to do? So far, we've been programming a bunch in YUI, which is pretty nice because it's so extensible. Most other toolkits, especially scriptaculous (or scriptalicisousness or whatever, here's a couple of dots to spray in random spots in the url: .....) are nice and fast but not as extensible as YUI.

  19. Re:Look who's talking by Claws+Of+Doom · · Score: 1

    It had me confused... spent a few minutes wondering how such an innocent post started such an AC choir. For me, it needs improving, if only because of that experience.

  20. You can right-click on Gmail by Walter+Carver · · Score: 1

    If you don't mind losing some of the Ajax functionality, you can switch to "basic HTML format"; it's a link at the bottom of the page. It will now behave a lot more Yahoo webmail.

  21. "Myspace Passes Yahoo in Pageviews..." by robogun · · Score: 1

    And the reason is, to quote from the article:

    "Yahoo continues to be the overall Web audience leader with the largest number of unique users and most time spent online. The page view change in November is related to the use of Ajax and other Web 2.0 technologies across the Yahoo network," Yahoo spokeswoman Nissa Anklesaria said Tuesday.

    So forget about Ajax if metrics mean anything to your bottom line. BTW, Ajax is making Yahoo a pain in the ass. All those little "helpful" popup balloon are just killing me and there's no way to turn it off.

  22. Re:AJAX's hatred of the middle-click. by amRadioHed · · Score: 1

    With Firefox and Opera, one is able to open a link in a new tab by middle clicking on it. But unfortunately, many AJAX-enabled Web apps disallow such functionality, for whatever reason.

    GMail is a major culprit. Being able to open a number of messages simultaneously is essential....


    I've had that problem with some AJAX pages too, thought it only rarely bothers me in gmail. Flash sites have the same problem, and I actually am annoyed by it in them way more than in the AJAX ones.

    And for viewing multiple gmail messages at a time, did you try the open in a separate window button? It works even thought it isn't tabs. Either that or you can go through the unwieldy process of opening a message, copy the URI, past into a new tab, go back to first tab, repeat....

    --
    We hope your rules and wisdom choke you / Now we are one in everlasting peace