PHP best practice: Function Parameters

I’ve been developing web applications for some years now, and while I make no claims to being the world greatest developer, I do figure, that I do have some solid experience which may help others or at least encourage thoughts and discussion. This is the first in a series of posts, and while it may be from a PHP developers point of view, it may applicable to other programming languages, and maybe even beyond web applications.

Build-in time bombs

I’ve been refactoring and refactoring some old code, and it’s kind of odd what short-cuts (or even time bombs), you’ll find in code, which apparently wasn’t supposed to live on for years. In a now retired CMS system, we had an issue every new year, when some kind of bug would reset all “schedules” for upcoming stories and content. No-one ever got around to fix it, as the system was soon to be decommissioned - but sadly the bug did survive a few years anyway.

Roaming todo-lists

I’ve been exploring todo lists for a while, but so far not found the ideal solution. I did however get a mighty step closer after Schack told me about a firefox plugin called Quickfox Notes. Before introducing Quickfox notes, let me spend a second on my daily workflow in broad terms. I usually have Firefox running 8+ hours a day. Either browsing the web, doing web development or just by habit.

Salvaging a deleted message from Thunderbird

Suppose you got an important mail, but by accident deleted the message – and to make matters worse, you also decided that emptying the mailbox was a pretty neat idea. Is then time to Panic? Well it might, but there is a chance you might be able to undelete the message – and quite easily if you’re on a Mac or a Linux machine. Here are the few steps, which has helped recover a lost mail or two… First close Thunderbird.

Ubuntu: Changing your IP number

Sure it doesn’t happen that often, but sometimes you might need to change the IP number of your machine running Ubuntu. Either to configure it with a static IP number on your LAN or temporarily to configure a Wifi router - the latter being my case. The first shot at changing the ip number, was going to the “System” menu, choosing Administration and Network Tools. It sounded just about right - but it’s wrong.