So, everyone and their dog has been on and on about AJAX. And, as a self-respecting developer, I figured I better figure it out. So, I did the sensible thing, and came up with a problem I thought AJAX would be good at solving, stole code from someone, and then implemented it in order to fix my problem.
You may remember that until today, my site would refresh every 2 minutes, if you sat here long enough (don’t worry, I’m not insulted if you didn’t sit here that long). The reason for this refresh was that I wanted the “Now Playing” bit down at the bottom left to always be up to date. I figured 2 minutes would guarantee that it would catch every song as it started playing. But on the other hand, this was skewing stats (page refreshes) and was annoying for anyone reading anything that took more than 2 minutes to read. So today, I stole some code from Kottke, added a little Javascript timer onLoad, and voila! Now just the “Now Playing” section refreshes every 2 minutes, leaving the rest of the page alone. Which, I think, is quite cool.
The silly, geeky thing is just how happy accomplishing this made me. I absolutely feel giddy with success, doing this incredibly tiny, easy little thing.
Yay you!
Yay you!
Yay! He uses Ajax. You should use our components. free licenses for buddies. let me know if you want to take a look.
Yay! He uses Ajax. You should use our components. free licenses for buddies. let me know if you want to take a look.