Last.fm Real Time Stats 2.0.2 is out now!

The latest version of Last.fm Real Time Stats is 2.0.2 as of now.
I’m leaving for Austria for four months, or so, at the end of this week, during which I’ll probably spend little time on this project. That and the fact that I’ve greatly improved things and added several new features are the reasons for this release. Moreover I’m planning on some new features that will require some database changes. It’ll close the gap between RTS and Last.fm In Time. It’ll be massive. Oh I love it all ready! :D

Well that’s for the future, this is now and there are some changes in this version:

  • You can now turn off logging and gzip compression in config.php
  • htmlentities() in statprediction.php
  • Bug: sorting between image and statprediction differs
  • Bug: Recent tracks seem not to update when a script is called.
  • Use XML data source.
  • Fix inefficiency with disconnecting before and reconnecting after recenttracker.php is called.
  • Fix low compression rates on logs.
  • Implement page counter
  • Bug: Very long artist or tracks names failed to insert. Cut off at 255.
  • Make this document HTML
  • Position are now the same for artists and track with the same playcount for image.php and statprediction.php

With compression for logging fixed you can now use it to compress your logs over 20×!
You can now safely use HTML in tags. Don’t know why you’d want that, but hey, it’s exploitable!
We now use strictly XML source files. This is good when you have comma’s in your tags. Because of this I also found a bug with extremely long tags, they’re now cut off at 255 characters.
I’ve also implemented a view counter for image.php and statsprediction.php so you can now easily see how often stats were displayed for a certain user in the all new management.php. This document shows you some statistics about the statistics, but is still far from finished!

That’s about all the interesting new stuff in here. Enjoy it and any comment is welcome!

Share

RTS 1 is shut down

I’m shutting down RTS 1.
You might’ve not even known there are two systems, because they output practically the same. Only, RTS 2 has a lot of improvements serverside. It’s much lighter and easier for me to run. I’ve ran both versions alongside for a couple of months so I could develop RTS 2 while all the users were on 1. RTS 2 runs on http://musicmapper.bit-byters.net/rts/ I’ve just added /rts/ to the end. This is to distinguish it from other things like Last.fm in Time. So to change all your images just add /rts/ to it as well and change last.fm.php into image.php. I’ve changed that since it’s more descriptive.

Or browse to:
http://musicmapper.bit-byters.net/
And generate new URL’s there as you were used to.
Continue reading

Share

Last.fm Real Time Stats 2.0.1 Released

Although I’m very busy lately, I’ve been putting some work into Real Time Stats. I’ve resolved some outstanding ToDo’s and now it’s been almost a month since the initial release, here it is: Last.fm Real Time Stats 2.0.1

Changelog:

  • fixed bug with color variable names
  • Improve Documentation massively! (actually mostly with 2.0.0…)
  • A footer include for e.g. Google analytics.
  • Parsetimes are now rounded
  • Make scripts week-parameter accept absolute week#. >1 is absolute, format WWYY, 2 digit year, 2 digit week.

That last option makes new value’s possible for the week selection. First you could only select weeks relative (e.g. 0=current, -1 last and 1 next week). Now you can do either that our enter an absolute number in the format WWYY, so 4107 would make week 41 in 2007.

What is there to be done:

  • Install script.
  • Management page.
  • Use XML data source instead of plain text.
  • Make the statprediction.php’ HTML IE compatible and HTML 4.01 strict compliant.
  • Fix low compression rates on logs. (they actually have negative compression)
  • Make a decent index.php (this is just a copy of a page from my web-site)
  • Use Mod_Rewrite
  • Use getval() function where possible
  • Fix inefficiency with disconnecting before and reconnecting after recenttracker.php is called
Share

Real-time stats for the masses, it’s OSS

I’ve put some effort into Last.fm Real-time Stats this week. The Database is now fully relational. Some more bugs crushed and stuff optimized. I wanted to release it this night, yesterday, the day before yesterday and before that, but all I did was more tweaking. Now I’ve decided that I just packed the last change into the release archive.

So here it is:
Last.fm Real Time Stats 2.0.0

Download it now and generate you own real-time stats. Because, admit, you don’t like waiting until Monday to see what you listened last week! You might need some experience with scripts, this is just the first release, but I’ve put quite some effort into the readme, so I hope you’ll be fine. Server requirements are:

  • PHP 5, 4 might also work, didn’t test it. (let me know if you do!)
  • With GD-PNG and zlib (change the log functions in the bottom of the functions file if you don’t have zlib)
  • MySQL, tested on 5.0.38
  • Cron Tabs (see FAQ)
  • Apache is recommended, because I use .htaccess to secure the /inc/ dir in a case of PHP parser failure.
  • A database management utility, such as PhpMyAdmin simplifies things a lot

If anyone is going to host the script and is willing to host the script for other people as well you can leave a message in the comments.

And why it’s 2.0.0? That’s because this one is fundamentally better than the previous version.

Share

Last.fm Real-time Stats is going to be OSS, sometime…

I’ve decided that Last.fm Real-time stats is going to be open source software. It’s been in consideration for a long time now, but it’s final. And I’m ever more liking the idea. At first I was a bit scared of just giving away my hard work, but now I think it’s more than that. I think it’s key to showing what you really created. Just showing the interface doesn’t tell much about a project.

So today I was looking at some work half done:
Bad Function
Can you spot the mistake?
More is the spoiler.
Continue reading

Share

Last.fm in Time

The idea
From time to time I like to code a little PHP and the other day I was looking at the audioscrobbler (the core, the data supply of last.fm) web services for interesting feeds and I saw the week chart feeds. I noticed that they provide a list of all available weeks and quickly realized that you could combine this with the Top50 feed to reconstruct older Top50′s. Just subtract an artists play count from next week’s total play count and you have the current total play count. And hey, if you can reconstruct old Top50′s you can view how they developed and how your musical preferences developed! Continue reading

Share