Home | Projects | Downloads | Contact Me | SQL Injection Attacks

A Few Updates

Well, it has been almost two months since my last post, but life has been a little on the crazy side.  Life gets that way from time to time I suppose.  Hopefully I can avoid being such a stranger in the future.

Recently, my friend Joshua Cyr introduced me to Plurk, a web site that strikes me as an improved Twitter-like social network.  After using the service for a few days it has really grown on me.  For those of you who are not familiar with the service, the updates you and your friends post shows up on a timeline showing the date and time of your plurk.  You can then add replies to the plurks and create a dialog.

After using it for a while, I realized the potential of using a timeline to represent time-based events.  Joshua was also kind enough to point me towards CFTimeline by Todd Sharp.  It allows you easily throw together a timeline based on XML or JSON data (honestly I have not had a chance to play with it other than quickly skimming over the documentation to view the implementation.)  I thought it would be cool to create a timeline off WhosOnCFC to see a timeline of current users logged in as well as the 24 hour history provided by WhosOnCFCStats. 

WhosOnCFC is now available for download

Well, I really don't like releasing things back to back, but it wasn't that hard to modify the latest version of WhosOn (which would be version 3 for those of you out there counting) to WhosOnCFC.  As the name implies, the new version moves to a component.  I tried to keep the implementation as close to the original system as possible.  Every request populates a structure with whatever information about the user you wish to track.  That information is passed to the WhosOnUserTracker() function which in turn adds or updates its user information, depending on whether or not the user is already being tracked.

Originally I was going to release WhosOnCFC with Rob Gonda's ObjectFactory CFC, but I haven't heard back from Rob and I did not want to release any of his work without his go ahead.  Dan Wilson was kind enough to point out Lightwire CFC, which is a light-weight object factory allowing dependency injection, but as I posted earlier it was still a little over-kill for my little demo application.  My thinking on this is, if you are advanced enough to using it, you probably don't need me to show you how to make it work with my component.

This is just a basic, functioning component with no bells and whistles.  It is intended as a basic framework for you to play around with.  It is packaged with an sample application to get you up and running.  As always, I would love to hear any questions or comments you have.  Again, I would like to thank all the really cool folks in #coldfusion on DalNet for helping me out when I needed some advice or just breaking the monotony of some generally boring days.

WhosOnCFC in the works

Well, I have started playing around with the newest version of the WhosOn user tracker.  WhosOnCFC is a component that is loaded as an application-scoped instanced component and keeps track of all the users on your web site.  I am working on the demo application for the release and as soon as I have all the kinks worked out I will have it released to the general public.

I am also waiting to hear back from Rob Gonda.  Currently I am using his ObjectFactory CFC which is overkill for a little demo application and I do not want to release it until I have his blessing.  I found it in the code for Raymond Camden's Galleon Forums application and since I have started using it I cannot say enough good things about it.  You use the ObjectFactory to handle creating your components.  If there is not already an instance of a component in memory, it creates it for you.  It also helps you handle dependency injection, but that is beyond the scope of this post.

I still have a few rough edges to work out, but overall things look promising.

WhosOn 3.0.0 available for download

Well, I was planning on getting this released by the end of the week, but I decided to go ahead and get it out the door.

This new version is a complete rewrite of the old system.  The old spaghetti code running the main function was removed and replaced with what is hopefully a more optimized version.  Also, the WhosOnline() function that returns the query object containing the users was completely rewritten.  No more hand-coding query cells when the user information structure changes as now it is all done on the fly.

The GetName() function was removed.  This was specific to my sites and I thought it was better to just remove it.

This is more or less just a basic framework for you to extend for tracking users active on your web site.  Any comments or suggestions are always welcome.

WhosOn version 3 coming soon

WhosOn user tracker is just a simple little utility I wrote way back in the day to track users on my corporate intranet.  One of my biggest gripes with it was it was a pain to make changes to it.  If you changed the information you wanted to track about each user there were quite a few other functions you had to change so your changes would be reflected in the output.  Another gripe is the fact the whole thing is more complicated than it needs to be.  I originally wrote the code years ago and I have not really made any attempts to update it.  Version 3 addresses both of these problems.

Originally I stored everything in a two-dimensional array which made things a pain to work with.  Now I create all the basic information I want to track on a user in a structure and just append our structure into the activeuser array.  If we are updating a users information we find their location in the activeusers array and update the structure members.

The other problem was making modifications to the function that actually creates the query object from the activeusers array.  Before, every change required modifying the WhosOnline() function to reflect those changes.  Version 3 will take a look at the elements in your user structure and dynamically create the fields for the query object.

WhosOn Monitor ready for testing

If you are using WhosOn tracker and would like to test drive WhosOn Monitor, I finally got it to the point that it is ready to be tested. If you are interested in checking it out just send me an e-mail. Once I get your e-mail I can send you a registration key. Once you get your registration key all you have to do is go to the Monitor site, enter your registration key and your domains should pop up.

There is no charge for registration or anything like that, your registration key is just a unique ID for you and your websites. It keeps others from being able to view your information.

WhosOn Tracker now with SES url parsing

Well, thanks to Ray Camden and his site Coldfusion Cookbook WhosOn Tracker now supports search engine safe urls. A small accomplishment in itself, but it does come in handy if you want to track who is viewing what in BlogCFC.

I will try to get the new version wrapped up and put in a neat little package soon.

In an unrelated note, Ray also just released his Database Explorer. It's a very handy little tool for running SQL queries against your Coldfusion datasources. It's a geeks multi-tool on steroids.

WhosOn Monitor

Since I have had some interest in the WhosOn Monitor, here is a screenshot showing the basic layout. I plan on having it finished up soon!

WhosOn User Tracker 2.2 and WhosOn Monitor

I got the next version of WhosOn User Tracker ready. The old way of updating the distributed tracker was scrapped and moved completely to web services. I have been testing this method of tracking on several sites for a few days and I haven't really noticed a slow down.

Also, for clarity's sake, I have renamed WhosOn Tracker to WhosOn Monitor. It's a little more descriptive and also it helps to tell the two projects apart.

Maybe one day I will actually get the Monitor finished up.

WhosOn user tracking actually works with BlogCFC!

I have WhosOn running on the blog. It was a big concern of mine how the code would actually interact with applications in a real-world enviroment. It is one thing to run in code I have written myself, the fact that it seamlessly integrated with something someone else has written just makes me feel all warm and fuzzy.

It would be nice to get the SES pages being tracked so you could actually see what people are viewing. That will probably be my next move.

[More]

Layout: Shane Zehnder ::: BlogCFC was created by Raymond Camden. ::: This blog is running version 5.9.