Social Networks


Follow sproutworks on Twitter
Enter your Email


Powered by FeedBlitz

RSS Feed

Links

Blogshares Links

The BlogShares fantasy blog stock market.

BlogShares Price Tracker
I wrote this program to archive information from the BlogShares fantasy stock market. You can view graphs of any industry, and analyze your portfolio.

SproutWorks Projects

Digg Archive
A new experimental Digg page.
AJAX Pixel Editor
A Collaborative pixel editor currently in development.
Web promotion links
These tools help you get visitors on your website.
SproutPics
My photography Site
SproutSearch
I designed this blog indexing tool, and it has accumulated over 6 million blogs so far.
Products
Some of the programs I've written.
SproutTree Demo
A demo of a tree-drawing PHP script.
My Gallery

Sign In

Username:
Password:
Remember Me

sprout man
Forums/People

sproutworks
July 9th, 2006 4:06 AM PST
I have been writing simple AJAX applications for a while now. Up to now I have stuck with procedural JavaScript that fetchs raw HTML and inserts it in the page. I knew these methods were lacking, but I used them for quite a while anyway.

I started reading about how to write object oriented JavaScript. I don't what took me so long to look into it. I've been using OO in C++ for about 10 years, and PHP for 3 years. I'm a big fan of objects. So tonight, I decided to write an Ajax object as part of a bigger scheme to buld myself a useful library for doing net stuff. I ran into some problems using a callback function for the xmlhttp response, but I figured it out.

Next I started reading about parsing XML and JSON. I decided to try JSON since it sounded easier. I made a PHP class that converts an array of derived classes into a JSON object. I made a simple callback to parse the object on the client side, and write some boxes full of fake data into the page.

Now everything is in place to use in a real application. I think I'll start with making an AJAX file/directory browser for a PHP project management system I'm developing. Then there are plenty of things I want to ajaxify.