Why an I blogging from my phone? Well it’s been a very busy weekend and I wanted to give this a shot. It’s amazing that we have the technology to be able to do what I am doing right now.…
From time to time I need to loop through a date range. One approach is to generate a start date and an end date and then add 1 day to the start date until it reaches the end date (or…
To start, let me put it out there that I’ve drank the kool-aid and have been doing a ton of hacking with Node.js (and soon enough, IO.js). I’m going to save the details for another post though. So an observation…
Converting a string to an array is a pretty common task when programming in PHP. If you don’t know much about PHP you could easily fall into a situation where you’re manually looping through each character in a string checking…
It happens to the best of us, you’re faced with a seemingly simple problem and you can’t figure it out to save your life. On the surface it’s easy but you start to get wrapped up in hypothetical situations and…
Arrays are a great way to store / work with data. In PHP, arrays are one of the most powerful data types of available. From time to time, you need to sort an array in reverse order. Of course, PHP…
Convenience is rarely economical. Shredded cheese tends to be more expensive than a block of the same type. Pre-chopped vegetables are the same way. But when you spend that little extra, you gain that back in time that you don’t…
Like most things, you can solve this problem with a number of different approaches. Without knowing about array_rand in PHP, you could end up doing something like this to pull a random value from an array: $array = [‘one’, ‘two’,…
Now that it’s starting to get cold out, which is anything below 70 degrees here in Florida, I have began searching to find a nice warm breakfast that is quick to prepare as well as portable. I tend to just…
Prior to PHP 5.3 the act of calculating the difference between two dates was a bit more manual than it is now. By manual, I mean there wasn’t a function that existed to aid in the process if by nothing…