[lang]

Present Perfect

Personal
Projects
Packages
Patches
Presents
Linux

Picture Gallery
Present Perfect

PHP hacking

Filed under: Dave/Dina,Hacking,Music — Thomas @ 23:34

2004-08-30
23:34

I was dead tired this weekend so I didn't feel like doing anything intellectually challenging. So I spent some time this weekend working some more on DAD. I actually quite enjoy working on PHP. The reason I do, I think, is because it's nice to take a bunch of code that actually works, even though it might not be structured correctly yet, and restructure it. PHP allows you to do stuff very quickly but also very ugly, and still have it work. Someone on IRC today said PHP is the BASIC of the web. Makes sense - lots of people learn PHP as their first language, and sometimes it shows.

Anyway, in the case of DAD, the code is quite good, but sometimes hackish in places. Sometimes Kristof just wanted to move quickly because I nagged for features. And when I tried something myself I didn't know enough about the advanced concepts to do it correctly.

So this weekend I focused on writing a class for the concept of having a popup detailing progress while some background action is taking a bit of time. I ended up learning about sessions to do it nicely (a previous hack used two temp files to track progress and errors) and it was a lot easier than I had expected. I worked on the class in a test directory using a bunch of sleep()'s, forcing myself to get it exactly right first before integrating it.

And when that was done, integration was dead easy, the code looks nice, is well-documented, and can now be used to delete a few hundred lines of code. I love it when a plan comes together.

Meanwhile, I've started to think again about my plans for a world-wide audio database. Lots of projects already exist, and all of them have fundamental flaws in either design, setup or community. Each time I think about it, I seem to solve a few more conceptual problems, and actually start believing that one day my ideas might actually make sense. There are a bunch of tricky bits to get right, and the hard problem will be finding people in the beginning that a) love music enough to see the value; b) have technical skills and c) have the tenacity to work on it for some time before it starts to be usable.

In other words, the plan will probably involve me having money to give other people work after finding a way to make this be sensible from a business point of view...

But I still have time, and I'm not quite happy yet with what I have so far.

No Comments

No comments yet.

RSS feed for comments on this post. TrackBack URL

Sorry, the comment form is closed at this time.

picture