Find the End of the Week with PHP

Just had a need to to represent the end of the current week in PHP. A quick Google search turned up a bunch of clumsy ways. The most common was to run the current date and day of the week through some math to get the date of Next Friday.

Fortunately thinking of those last two words reminded me of an easier way, and one that I use in BASH occasionally. PHP's strtotime function takes a similar language that GNU Date does. So to find out the date of next friday, just use this line of code:

$week_ending = date('Y-m-d', strtotime( 'Next Friday'));

You can also use "This Friday" which will return today's date on a Friday instead of a week from today.

New Life for an Old Domain

As some of you know, I also write (wrote) for a blog at lr2.com.  It was a reasonably popular links blog when I cared to post a few times a day.  In the last two years I have all but ignored the site, and traffic has fallen steadily as a result.

Since I am already stretched to write enough content for here, and GeekDad, I have decided to re-purpose lr2.com as a short url site.  I realize there are a lot of sites out there that do this, but I think there is room for one more.  It should run nearly maintenance free, and eventually provide enough network traffic and ad views to help pay for my web hosting.

So if you need some URLs shortened, give it a shot, and feel free to use them in your emails, IMs, and blog posts.

2008 SXSW Interactive Panel Picker – Testing Two-Step

2008 SXSW Interactive Panel Picker

A humorous look at Why, What, and How to test. Why we should test our web applications. What part of the applications need testing. How to steer development to help with testing. How to use free testing tools to make your applications rock a step or two above the competition. Dual presentation with Mark Morga.

Mark's and my panel suggestion for SXSW 2008 is up for vote on the new and improved panel picker.  If you have a moment and don't mind registering, please go rank your favorite panel ideas.  If enough technical people sign up and vote I think we'll have a reasonable chance at being selected.

We'll have more to post about in the very near future as we get the Testing Two-Step site up and running.

LOLCat Generator

lolcatgraph.pngWhoa, that's some crazy growth.

I launched LOLCatGenerator.com earlier this week and the growth rate is crazy. So far I've got just over 200 cat pictures up and ready for captions.

More features should follow this weekend and next week as I get time to work on them.

Setting Type on the Web to a Baseline Grid

baseline.jpg
A List Apart: Articles: Setting Type on the Web to a Baseline Grid

Over the last year or so, there’s been a lot of talk about grid systems and using column grids for website layouts. Mark gave us a lesson plan, Khoi gave us a case study and Cameron gave us a toolkit. The message is clear: we have the browser support, the know-how, and the tools we need to create consistent multi-column grid layouts on the web.

Some good tips and resources for grid layout at A List Apart. Now I just need to find the time to fix this layout.

Saturday 4pm – Ruining User Experience

It's all about the water. Or more specifically it's really the small aspects of one's meal that determine how well you appreciate your waiter. The same holds true for web applications. It's not how well the app does it's job but more about how much it annoys you. Any annoyance is a barrier to entry and will keep or drive your users away.LaLa.com was the first example on the chopping block. It requires javascript, doesn't downgrade at all, and won't work on mobile browsers. While LaLa was a favorite site of Aaron's it was would, and most likely has, driven away others who would find it useful but can't get past the barriers.

When building a web application, start with the no frills set. Be sure everything works and then offer a slightly dressed up version. Cool colors, better layout, and nicer fonts appeal to a lot of people but might hinder a screen reader or phone browser. Be sure they aren't required for a usable experience. Lastly add the whiz-bang items like ajax, javascript form validation and animations. Again, be sure they don't get in the way and that they aren't required.

Usability and accessibility is key. It won't matter how pretty your site is if people can't use it they won't.

Aaron Gustafson Sr Web designer/Developer, Easy! Designs LLC
Sarah Nelson Design Strategist, Adaptive Path

Saturday 3:30pm – Grids are Good

I must have forgot to take a pic during this session so I'll have to steal one from Mark when he gets his processed.

Grids are Good! Yes, they are. Mark Boulton and Khoi Vinh did a great job of explaining how to layout a web page on a grid. They explained the constraint of the browser width, ad unit sizes, and ways to split the page up into multiple columns and bring those columns together as needed for the design.

Mark Boulton Owner, Mark Boulton Design
Khoi Vinh Design Dir, The New York Times