Thursday, August 10th, 2006

Adding AJAX to a Website step by step, Part II

Category: Library, PHP, Programming

<>p>Back with the second part of his postings on adding Ajax to a website, Joshua Eichorn has this new item on his blog today (picking up from this previous post) – a look at polling the server for the latest data with the HTML_AJAX PEAR package.

I have a lot more change’s i’d like to make to webthumb so the last article (Adding AJAX to a website step by step) is now the start of the series. In this article will be taking front page of webthumb and making it live. The the stats and recent thumbnails will update in real time, making for a nice slick presentation.

He first focuses on getting real-time information back with the help of Ajax. In his case, it’s grabbing the latest thumbnails created by the application, fetched by periodic polling back from a timed script performing an Ajax request.

He moves on to the code, showing how to export the PHP class for the updater, a sample result for the request and the code for the actual server the Ajax request will be made to. Then, it’s back to the client side of things with the Javascript needed to make the call back to the server, parse the response, and update the page with the latest information.

There’s also a little aside that talks about how the HTML_AJAX package delivers it’s Javascript libraries and how this can be used to grab and push out the moo.fx library along with the other scripts to create a a fade in and out of the updates made to the page to make them more apparent to the user.

Related Content:

Posted by Chris Cornutt at 7:49 am
1 Comment

+++--
3.5 rating from 38 votes

1 Comment »

Comments feed TrackBack URI

It’s a very nice article about adding AJAX to a website. Just what I was looking for.

Comment by Website designer UK — August 14, 2006

Leave a comment

You must be logged in to post a comment.