Sponsored by HTC
You and You and You. view!
youtube.com - You don't need to get a phone. You need a phone that gets you.
64 Comments
- titlesaysitall, on 10/12/2007, -3/+30The World says hello back.
- yongfook, on 10/12/2007, -2/+24Rasmus' 30-second AJAX tutorial explained this much better.
http://rajshekhar.net/blog/archives/85-Rasmus-30-second-AJAX-Tutorial.html
and like, a year ago. - olddirtycr, on 10/12/2007, -1/+22Wow hes obviously kidding if you people can't pick that up you fail at life.
- Cl1mh4224rd, on 10/12/2007, -8/+28"Odds are if you found this tutorial, then you have created a "Hello World!" program before."
Whoops! The odds just got a lot lower by posting this to Digg... - i440, on 10/12/2007, -12/+28Unfortunately, there have been many, many misconceptions about Ajax, ranging from it's purpose to how it works. Luckily, I have come to set the record straight and eliminate any confusion once and for all.
Ajax is a programming language primarily designed for the creation of Web 2.0 pages. All Web 2.0 websites have the following features:
1. gradients;
2. rounded corners; and
3. content that disappears or moves on the page.
The language, which is actually usually written in upper case (AJAX) is compiled and runs on the webserver. Some of its methods include rendergradiant(), rendergloss(), makeappear(), makedisappear(), and cornerround(). It is a little known fact that AJAX is responsible for rendering almost any glossy graphic currently associated with computers. The image is fed into AJAX and rerendered using special algorithms that seem to encase to graphic or element in a layer of glass. Specifically, Apple Computer has been known to make extensive use of AJAX in Mac OS X.
Above all else, remember: if it's a website, and it has gradients, it's always AJAX.
You're welcome. - JeeBs, on 10/12/2007, -0/+14Check out http://digg.com
- yongfook, on 10/12/2007, -1/+14you misunderstand - the link I posted may or may not have been on Digg (I found it via a web developer blog some time ago), but it is far better at providing a simple introduction to AJAX than the article posted.
Age doesn't matter really, but if an old article does something way better than a new article (or, at least and article recently posted to the Digg front page) I think that's a good enough excuse to post it again and whinge a bit, like I did. - Alex.w, on 10/12/2007, -0/+9Dam kael, how did you not get that was a joke by the time he got to "AJAX is responsible for rendering almost any glossy graphic currently associated with computers."
I guess you stopped reading his post after the second word, is a rush to troll him in reply. - oSiBo, on 10/12/2007, -2/+11i440 thank you for that post describing so well that so called "Web 2.0". That made my day :)
- bondo, on 10/12/2007, -0/+9The successor to AJAX, currently called BUZZWORD, will have even more compelling features, such as sweet native text scrolling and blink effects.
- Shinta, on 10/12/2007, -0/+8You missed gradiented logos and zippy names like Digg or youtube.
- psylence, on 10/12/2007, -0/+8i440: Thank you for baiting out a few of the people that make digg so entertaining.
Even after olddirtycr attempted to help them. This tends to help in most cases: http://en.wikipedia.org/wiki/Sarcasm - CaseyUCF, on 10/12/2007, -6/+14Hitting a static HTML file with an XMLHTTPRequest is pretty lame imo.
hardly ajax - yongfook, on 10/12/2007, -5/+11wrong. AJAX is characterised by flashy transitions. In fact, all Flash-based sites are excellent examples of AJAX.
- shortkid422, on 10/12/2007, -0/+6No, you're missing something. Everything has to have a reflection, as if the entire internet is on a super-shiny floor. Duh!
- seventoes, on 10/12/2007, -0/+5http://www.jquery.com/
- RexyRex, on 10/12/2007, -0/+5http://en.wikipedia.org/wiki/AJAX
Bam.
As for the tutorial, I like Ramsus's 30 second tutorial much more because that's the one that made it 'click' for me. This one works, but so do about three billion others. Check out the links on Wikipedia. - ojk007, on 10/12/2007, -3/+8i enjoyed this line of code
alert("Your browser doesn't support the XmlHttpRequest object. Better upgrade to Firefox."); - Sanctity, on 10/12/2007, -4/+8Reported lame. Just mention the word AJAX and you have a front page story.
- cozinator, on 10/12/2007, -5/+9"Thank you for not setting the record right at all. AJAX is not a programming language. It uses javascript to make the asynchronous calls if that is what you are referring to. Also AJAX is not compiled or run on a webserver."
WOOOSHHHH! - gerkin, on 10/12/2007, -1/+4innerHTML has some inherant problems in modern browsers ... if you want to learn about AJAX you should probably read up a bit on why NOT to use innerHTML :)
That example is pretty ghetto, I must agree. - yongfook, on 10/12/2007, -0/+2totally agree. After reading the Rasmus tutorial some time ago, I made my first AJAX-enabled app within a matter of hours. It really is the one that made it all click for me. A year or so on, I'm now heavily involved in AJAX application development at my job.
- dSlifer, on 10/12/2007, -1/+3And how far are you?
- RexyRex, on 10/12/2007, -0/+2http://www.maps.google.com
http://www.gmail.com
Everybody loves Google. - springfield, on 10/12/2007, -0/+2I know what you mean but the reason the author probably did that is because this method is agnostic of the way you generate your content. If he had built the demonstration with mod_perl at the backend then people might have lost interest or skipped over it making the assumption that without mod_perl experience they wouldn't be able to follow this article.
- yahoofrom, on 10/12/2007, -0/+2why not?
InnerHTML and ChildNodes blah blah, they all have their own pros and cons. - RyanSmith345, on 10/12/2007, -0/+1For whoever dugg this, thanks. I wrote this tutorial about 4 months ago as a simple introduction to AJAX technologies. I know there are other tutorials out there, and many of them are probably much better than mine. If you took something away from this tutorial, I'm glad, if not, I'm sorry you wasted your time but I hope you can see the value in it for others.
There are a couple of comments that seem grossly misinformed.
First off, AJAX is not a compiled language or even a language at all. AJAX is a set of existing technologies working together to create interactive web pages. AJAX stands for Asynchronous JavaScript and XML, but to me it basically means using the XmlHttpRequest object so you don't have to reload the entire web page in order to get new content from the server. Any AJAX developer will tell you that's the main concept.
Second off, someone was claiming that this was sloppy coding because I used the innerHTML property. I don’t mind if people think my coding is sloppy, one of the traits of a good programmer is that we are always trying to improve our coding techniques. However, the only argument that I could find for NOT using innerHTML is the fact that it doesn’t work in IE 5 for the Mac. If you are wasting your time trying to write code so that it will run for the .000001% people still using IE 5 for the Mac, you might as well try to build the Three Gorges Dam using popsicle sticks.
Finally, there was some remarks about how this isn't useful, and that using a plain text file on the back end is pretty lame.
“Hitting a static HTML file with an XMLHTTPRequest is pretty lame imo.”
The reason this was a simple static HTML file on the backend was because it's completely language independent. You don't even need to have a web server to run the example. Hello World was not intended to be a useful web application. It was intended to be a very simple introduction to AJAX.
That being said, I appreciate everyone who took the time to look at and comment on my tutorial - both positive and negative. - ijustfloat, on 10/10/2007, -0/+1One argument for the fact that innerHTML is bad is the fact that it's deprecated by the W3C. I mean, they just write coding standards for the web, so y'know I don't know if that's a good argument or not.
- RexyRex, on 10/12/2007, -1/+2Digg had a problem handling that link (because I edited the comment), you'll have to copy/paste the URL. So sorry.
Or if you're lazy, click it here: http://en.wikipedia.org/wiki/AJAX - ephemeral, on 10/12/2007, -0/+1Are there any other users on here that get frustrated with the fact that people try to run complex applications inside of a browser?
Every time I use a "web app" I feel like I'm trying to move a king-sized bed with a Toyota Prius. Thank you world wide web for ruining the desktop application. - gerkin, on 10/12/2007, -0/+1it's not just IE 5.2 for Mac that's a problem... most modern web browsers try to render things before they are completed and when using innerHTML this is a problem. Try googling it a bit. Having built quite a lot of ajax type sites I can tell you there is a big difference using this shortcut.
- MrViklund, on 10/12/2007, -0/+1Great :)
- tybris, on 10/12/2007, -0/+1Yeh, if you care about Internet Explorer 5 for the mac...personally I don't, but things like nodeValue are indeed better.
- gerkin, on 10/12/2007, -0/+1Yep the Ramsus tutorial made me think differently about the whole ajax scene as well, and made me realize I was already doing it :)
- plumeria, on 10/12/2007, -0/+1ROFL - love that post. Some seem to totally take it the wrong way, i.e. serious. ;)
- llbbl, on 10/12/2007, -1/+1OMFG AJAX +digg :P
- yogastore, on 06/27/2008, -0/+0http://astore.amazon.com/holmes.tower.fan-20
http://astore.amazon.com/honeywell.tower.fan-20
http://astore.amazon.com/10.cup.rice.cooker-20
http://astore.amazon.com/zojirushi.10.cup.rice.coo ...
http://astore.amazon.com/bug.zapper-20
http://astore.amazon.com/rat.zapper-20
http://astore.amazon.com/250gb.external.hard.drive ...
http://astore.amazon.com/500.gb.external.hard.driv ...
http://astore.amazon.com/surfboard.cable.modem-20
http://astore.amazon.com/wireless.cable.modem-20 - fabriciom, on 10/12/2007, -0/+0I don’t understand what’s with the AJAX hype. Its nothing new and all it does is it sends a (POST/GET/HEAD) with out having to refresh. BIG WOOPDIDOO! How about a constant connection with the server where the server lets the browser knows when to request data. Now that would be interesting, and it’s supposed to be implemented by something called COMET which has yet to see the light on Apache.
-Fabricio Martinez
-http://www.fabtechsolutions.com - sidneykr, on 10/12/2007, -0/+0This is not another AJAX tutorial, but could be an AJAX sample. http://www.noovo.us/demo
- comart, on 10/12/2007, -1/+1Just apply AJAX to page navigator on http://dholes.pxax.com
can't use getElementById() on innerHTML's content ! - tallguy78, on 10/12/2007, -0/+0very nice! I'm not nearly good as you but here's another sample I did.
http://www.weekendstory.com - rdivilbiss, on 10/12/2007, -0/+0I think the example is overly simple and does not introduce anything useful to the budding AJAX programmer.
1. It isn't even AJAX (which implies an XML response), but AJAX is a catchy name.
A more functional example using the HTTPRequest object to hit a server side service (with ASP and PHP source).
http://www.expertsrt.com/tutorials/Rod/ajaht.php
But seriously, to be useful you need a method to debug, handle errors and more extensive code to ensure your xmlhttp object works correctly with Opera, Safari and some other browsers (all of which bring their own quirks.)
Even for a beginner, including a good xmlhttp library, such as Dojo, will let you concentrate on creating functional code while ensuring your HTTP Request will be properly handled regardless of the client's browser.
For example: http://www.suspendedexpert.com/AJAX/sayHello.htm - axykim, on 10/12/2007, -0/+0Just to let folks know, The "10 week free AJAX online programming" course just got started. Please check it out. The course deals with AJAX basics, tools, Dojo toolkit, Google Web toolkit, jMaki, JSF, etc. For detailed info, please see course website below.
http://www.javapassion.com/ajaxcodecamp/ - MidasShrugged, on 10/12/2007, -0/+0hey alright! this is whats digg all about!
would be nice if there was some things about apple and ipods and maybe some infos on some alternative fuel or even some global warming in there, but i dig it anyway. - tybris, on 10/12/2007, -3/+2oh please, enough with the Ajax tutorials already. Come on people, It's REALLY SIMPLE.
- useresu, on 10/12/2007, -2/+0How many tutorials on a few lines of code do you have to read to understand this?? Geeez. It's not even funny any more.
By posting the 10000000.....000th tutorial on this you're trying to say that "It's not that common, it is a big deal and it doesn't happen to everybody!" ?
Grow up. - inactive, on 10/12/2007, -4/+2can someone show me some decent uses for AJAX?
- changyang1230, on 10/12/2007, -3/+0I am a newbie, so can anyone tell me why I am being buried?
- glafira, on 10/12/2007, -7/+3Ive always wanted to learn as many programming languages as possible.
-
Show 51 - 65 of 65 discussions

What is Digg?