How To Sort A Multidimensional Array By One Element In PHP

I had a table’s worth of listings and had stored all the values in a multidimensional array in PHP. The problem was, I needed to sort the multidimensional array, but based on just one element. Here’s the easiest, fastest solution that I found from the array_multisort function page of PHP (thanks to zequez at gmail dot com!). Here’s his original solution taken from that page: $multiArray = Array( Array("id" => 1, "name" => "Defg"), Array("id" => 2, "name" => "Abcd"),

Continue Reading

How To Fix MTP Failed or CDC Failed Errors When Connecting Your Samsung Galaxy S via USB

Today, I tried plugging in my Samsung Galaxy S, an Android phone, to my computer, thinking that I could transfer some files to it. Surprise, surprise, I was greeted by an error stating that there was a problem installing the USB drivers for my phone. Windows Update didn’t seem to have any drivers for this too, so I went to Google for “USB drivers for Samsung Galaxy S” and found it! There are two packs that you can use, depending

Continue Reading

How Does FireFox Weave Sync Benefit Me?

Mozilla Labs has been working on Weave, an official bookmark-syncing extension for Firefox. The newest version of Weave is out of beta, and on top of just bookmarks, it also supports syncing your FireFox history, passwords, preferences, location bar, and even your open tabs. It isn’t at a point where I would say that it’s reliable. For example, currently it only supports up to 25 open tabs, but sometimes depending on the project that I’m working on, I have 30+

Continue Reading

How To Install IonCube Loader On MAMP On Your Mac

MAMP (Mac, Apache, MySQL, PHP) is a package that allows you to run your own PHP-enabled web server with MySQL easily on your Mac. However, if you’re looking for additional libraries like the ionCube libraries, you’ll need to download and install them yourself. That’s not bad because it’s not hard at all. What you need is to go to http://www.ioncube.com/loaders.php, and download the ionCube loader file for your O/S version. For example, I’m running a Macbook Pro unibody, and so

Continue Reading

How To Resolve Kernel Panics in Mac OSX

I had the fantastic opportunity to be the lucky recipient of kernel panics on my Macbook Pro that happen once every 24-48 hours. I’ve been trying to troubleshoot and resolve the kernel panic, because as you can imagine, it’s extremely counter-productive. I finally resolved it by removing a wonky KEXT (kernel extension) that turned out to be the culprit – turns out it was USBOverdrive’s KEXT, and this all started when I used USBOverDrive to configure my bluetooth mouse because

Continue Reading

Bloated SnagIt Screencapture Utility

I hate it when I want to do something but have to wait for it. I know, I know, it just goes to show how impatient I am, but don’t we live in the age of instant gratification where everything must be done in the snap of your fingers. Screen capturing is something that I (probably) do on a daily basis, so imagine my annoyance when something like screen capturing can’t be done in a quick, painless process. My basic

Continue Reading

Sliding Sidebar