NOTE: The latest version of this script can always be found here: http://github.com/PHLAK/first-friday/blob/master/first-friday.php
With this update I have drastically reduced and simpified the code to produce the same results. I did some rigorous testing of my own to make sure this script will calculate the correct date, but that doesn’t mean it’s bullet-proof. If you find a bug, please email me so I can fix it.
first-friday.php
// Calculate next Friday
for ($x = date('d'); $x <= (date('d') + 6); $x++) {
$timeStamp = mktime(0,0,0,date('m'),$x,date('Y'));
if (date('w',$timeStamp) == 5) {
$nextFriday = mktime(0,0,0,date('m'),$x,date('Y'));
}
}
// Check if next Friday is the first friday of the month.
if (date('d', $nextFriday) <= 7) {
$firstFriday = $nextFriday;
} else {
// Calculate first Friday of next month
for ($x = 1; $x <= 7; $x++) {
$timeStamp = mktime(0,0,0,date('m')+1,$x,date('Y'));
if (date('w',$timeStamp) == 5) {
$firstFriday = mktime(0,0,0,date('m')+1,$x,date('Y'));
}
}
}
// Echo next first Friday
echo date("F j, Y", $firstFriday);
?>
I went to the Verizon store at 10am the day of release and they said they had sold out ~2 hours before I got there. I was able to order one and they were nice enough to write off the rebate right away and overnight me a Storm directly from the factory. By noon the following day I had my Storm and the following are photos of the unboxing. I know this is rather late, but like they say, better late than never.

Continue reading “BlackBerry Storm Unboxing” »
The following is a quick list of optimizations that, in my years of web development, I have observed will help increase your sites search engine ranking. While none of these processes are guaranteed to make your site #1 in Google overnight, I can promise that by implementing all (or even some) of these items, in time your site’s rank will rise.
The following items are clean, honest ways to optimize your site. I do not condone, nor solicit, any form of “black hat” search engine optimization and frown upon it greatly. If that’s what you’re aiming to implement, I sincerely hope that Google blacklists your site tomorrow. Please don’t send me any emails asking how to get your sight listed as #1 tomorrow.
Now, onto the list.
Continue reading “Beginers Guide To Search Engine Optimization” »
So, Gizmodo had a list of 50 skills every geek should know. Seeing as I choose to don the title of “Geek” I feel obligated to see how many of these skills I posses.
Skills marked in Bold are skill I have and have used, or have all the essential knowledge to perform without reference. My notes are [encased in square brackets].
View the original article @ http://gizmodo.com/5078829/the-50-skills-every-geek-should-have
Check out the list after the break.
Continue reading “How Geek am I?” »
UPDATE: This script has been updated, see: http://www.web-geek.net/posts/2009/02/14/first-friday-script-updated-and-simplified/
While developing phx2600.org, I ran into a slight dilemma. The PHX2600 meetings occur once a month on the first Friday of every month, and we wanted to display that on the site. However, it was becoming a tedious chore to change the date once a month manually. So, being the automation addict I am, I thought, why not write a script. So one night I hammered out the following script that will calculate the first Friday of next month:
Continue reading “Calculate the first Friday of next month with PHP” »
Part 2 of my Free Alternative Lightweight Software for Windows will cover basic security and performance enhancing/maintenance tools.
I have broken this article into four parts to make it easier on both you, the reader, and me. As I publish the other sections of this article, I will add a link to them.
Replaces: Norton Antivirus, McAffee Antivirus
Alternatives: AVG, Avira
Pros: Unobtrusive, Lightweight, Fast
Avast! antivirus is powerful anti virus software, but, unlike its mainstream competitors, Norton and McAffee, you’ll barely be able to tell that it’s there. Avast! is lightweight and unobtrusive, it wont bog down your system and barely bugs you unless it finds a virus or other malicious code. The home edition of Avast! is free for 13 months if you register it, and when it expires, all you have to do is register again to get another 13 months of updates.
Download Avast! Antivirus: http://www.avast.com/eng/download-avast-home.html
Mirror: http://www.filehippo.com/download_avast_antivirus/
Continue reading “Free Alternative Lightweight Software for Windows (Part 2)” »
Sick of your computer running like molasses? Tired of having to perform that annual (semi-annual?) reformat and installation of your operating system? Do you wish your computer just ran faster? Well maybe some free alternative lightweight software will solve your problem! On the other hand, if you enjoy the time you have to make coffee while you load that simple .PDF file, please stop reading now.
I have a fairly complex, yet powerful, Windows box that I run as my primary machine and it runs great. Now this is by no coincidence, it’s taken some hard work to make this thing run like a well oiled machine. I do, however, owe a great deal of thanks to the plethora of free (as in beer), lightweight software I have installed. What software you might ask? Well here’s a list I’ve compiled of some of the best software I’ve run into that will keep your computer from slowing down and your resources free so you can do more important things, like surf for porn.
I have broken this article into four parts to make it easier on both you, the reader, and me. As I publish the other sections of this article, I will add a link to them.
Continue reading “Free Alternative Lightweight Software for Windows (Part 1)” »
So you’ve got a 10-year old PC sitting around the house. You’re sick of your cats always getting into the wires and knocking the darn thing over. You don’t want to throw it away, but you just don’t know what to do with it. Well my friend, why don’t you turn that thing into a new hardware firewall?!
How would you go about doing that you might ask, well I’ve got the solution for you: IPCop!
What is IPCop?
IPCop is a secure Linux distribution managed through a web-interface. It turns an old PC into a firewall and VPN gateway. Features an Intrusion Detection System. Check it out at http://www.ipcop.org.
What are the hardware requirements for IPCop?
I ran IPCop on an old system I had lying around. Specs:
- Pentium 2
- 320MB PC100/133 RAM
- 20GB HDD (Overkill, but the smallest I had)
- 2 NICs
- ATI Rage 8MB Video Card *
- CD ROM *
- Cardboard and packaging tape (to keep as much cat/dog hair out as possible… and for STYLE!)
* Only needed for install
The actual requirements are pretty low. You probably only need a 2-5GB hard drive, smaller if don’t plan on keeping any logs. Also, if you’re not planning on running the intrusion detection system, you could get away with 64MB of RAM easily.
Continue reading “Turn your old PC into a hardware firewall with IPCop” »