PHP MySql Database Class / Library
I was looking for a good out of the box library or class I could use as a singleton to manage database interactions in one of my PHP projects, and after rejecting Pear MDB2, PDO, ADODB and dbFacile I came across just what I was looking for: DbSimple, which satisfies all the requirements I have:
- Easy to use interface functions
- Conditional queries, escaped arguments for secure queries and prevention of database injection attacks
- Error handling, connection management
- Open source license
It looks daunting at first because the package comes with numerous files, but the usage is quite simple after you upload it; something like this is enough to get started:
require_once('DbSimple/Generic.php');
$DB = DbSimple_Generic::connect("mysql://user:pass@localhost/db");
$DB->query( "DROP TABLE table");
A feature which I probably won’t use as much is the transactionality–you can open, commit, and rollback mysql transactions to bundles your queries together.
MacWorld MacRumors Live Feed Hacked
I was watching the MacWorld 2009 Apple Keynote live when a message appeared in the feed–”STEVE JOBS JUST DIED”–surprising everyone. In a few minutes, the MacRumors feed was full of coordinated hacked spam:

Highlighted is the beginning of the spam
MacRumors apologized for the incident: “Our MacRumorsLive keynote coverage was hacked today, inserting inappropriate content into the text and photo feeds. We apologize for the inconvenience and are working to restore our services.” However, it was simply negligence on their part for having a control panel which was publicly accessible rather than some kind of nefarious hack. One of the nicer 4chan readers took this screenshot of it before it was taken offline:
See also When Livestreams Go Wrong and 4chan’s /g board where the chaos originated. Hopefully this will teach bloggers and web startups to pay more attention to the security of their websites, as hacking websites is growing more and more popular with savvy internet pranksters.
Steve Jobs’ Health
Today Apple released a press release, a Letter from Apple CEO Steve Jobs informing the world that his weight loss is not a recurrence of his pancreatic cancer, and that he is able to continue carrying out his duties as Apple’s CEO while recovering from his “hormone imbalance:”
Dear Apple Community,
For the first time in a decade, I’m getting to spend the holiday season with my family, rather than intensely preparing for a Macworld keynote.
Unfortunately, my decision to have Phil deliver the Macworld keynote set off another flurry of rumors about my health, with some even publishing stories of me on my deathbed.
I’ve decided to share something very personal with the Apple community so that we can all relax and enjoy the show tomorrow.
As many of you know, I have been losing weight throughout 2008. The reason has been a mystery to me and my doctors. A few weeks ago, I decided that getting to the root cause of this and reversing it needed to become my #1 priority.
Fortunately, after further testing, my doctors think they have found the cause—a hormone imbalance that has been “robbing” me of the proteins my body needs to be healthy. Sophisticated blood tests have confirmed this diagnosis.
The remedy for this nutritional problem is relatively simple and straightforward, and I’ve already begun treatment. But, just like I didn’t lose this much weight and body mass in a week or a month, my doctors expect it will take me until late this Spring to regain it. I will continue as Apple’s CEO during my recovery.
I have given more than my all to Apple for the past 11 years now. I will be the first one to step up and tell our Board of Directors if I can no longer continue to fulfill my duties as Apple’s CEO. I hope the Apple community will support me in my recovery and know that I will always put what is best for Apple first.
So now I’ve said more than I wanted to say, and all that I am going to say, about this.
Steve
This comes in response to a post on Gizmodo, Steve Jobs’ Health Declining Rapidly, Reason for Macworld Cancellation, which alleges that “Steves health is rapidly declining. Apple is choosing to remove the hype factor strategically vs letting the hype destroy apple when the inevitable news comes later this spring.”
When this latest revelation is coupled with the previous delays we’ve seen in reporting Job’s health problems, the only thing we can expect is worse news. If you follow Apple and appreciate its products, do not be surprised if Steve Jobs resigns as CEO, or is replaced by the Apple board following a deterioration in his health, or death.
Update: It appears that the common thought that Jobs is sicker than Apple’s willing to admit was true. Apple just released a press release stating that Steve Jobs’ “health-related issues are more complex than [he] originally thought” and that he “decided to take a medical leave of absence until the end of June.”
Please see Disclosure & Legal Notice for information about conflicts of interest and this post. Disclosure: Short Apple at time of publication.
