Browse >
Home / Archive by category 'design corner'

Because of recent demand, I decided to release my PHP video tutorials in iPod format - that means they play on your iPod.

… OK, you guys guessed that one.
Read more
Written by stefan mischook · Filed Under design corner | Comments Off
This PSD will be selling exclusively on PhotoshopCandy.com for 1 week ( Feb20 - Feb27, 2008)
VIEW SCREEN SHOT HERE
NOTE: You can-not re sell it as a psd template.
The PSD will be selling exclusively on photoshopcandy for 1 week only.
Price:$49.00
After that time, the psd will be removed from the site.
TIME IS UP! - SORRY GUYS.
If [...]
You like this cool outline effect? So do I - and the fun part is that it takes about 2 seconds to do!
We will do it in 3 easy steps:
Step 1:
Using the Type tool - write whatever you want using a nice full font. ( no serifs please)
Step 2:
Double click on that layer to [...]
This is part 3 of 3 of my videos that introduces beginners to PHP sessions.

In this video, I conclude my practical look at basic PHP sessions.
PHP session video tutorial - part 3
Thanks,
Read more
Written by stefan mischook · Filed Under design corner | Comments Off
This is the part 2 of 3 of my videos that introduces the beginner to PHP sessions.

In this video, I get into practical examples where we see basic PHP sessions in action.
PHP session video tutorial - part 2
Thanks,
Read more
Written by stefan mischook · Filed Under design corner | Comments Off
Stuart Colville pondered the potential for
using setTimeout to solve the DOMContentLoaded problem in browsers that don't support it, namely anything but Opera and Mozilla.
His code is deceivingly simple:
function DOMReady(f){
if (/(?!.*?compatible|.*?webkit)^mozilla|opera/i.test(navigator.userAgent)){ // Feeling dirty yet?
document.addEventListener("DOMContentLoaded", f, false);
}else{
window.setTimeout(f,0);
}
}
Then, to make use of this, simply call DOMReady, passing in the function you want to execute when the page has loaded.
Read more
Written by Jonathan Snook · Filed Under design corner | Comments Off
Hi,
I’ve just released a new beginners video tutorial that introduces people to PHP sessions:
PHP Sessions Video Tutorial
PHP sessions are one of the most important mechanisms in PHP because they solve a fundamental issue in web application development: keeping state on a user.

If what I just says confuses you, no worries, it’s explained in the video.
Read more
Written by stefan mischook · Filed Under design corner | Comments Off
“
CommandShift3 is like Hot or Not. Except, instead of clicking on hot babes, you click on hot websites.”
A very straightforward concept and one that has definitely caught on with a bunch of people. One of the neat things they've done that I like, is the video you see when you submit your site. They've conveniently compiled a list of
all the videos for your perusal. Ben Brown and Taylor McKnight are probably my two favourites of the list.
Beyond that,
Elliot Jay Stocks got asked to put together a special video for their 404 page. I left a comment on that post about doing a video. Lo and behold, they saw the comment and asked if I'd do a video. (See, it never hurts to ask...even in an off-handed way.)
If you'd like to see said video, try to find
a page from the unknown. You may have to refresh as it'll randomly choose a video between myself and Elliot. (And yes,
I bought a webcam just to do this video. Although, trying out
Ustream.tv and
Y! Live has been fun, too.)
Read more
Mention comment spam and most people, in particular those crazy WordPress users, mention Akismet. Great tool and I have nothing against it but I wanted to build my own, avoiding the external call to the Akismet service. What has been interesting to see, is just how effective it is. Turns out, my spammers are quite obvious.
As you might see, I don't use CAPTCHAs and I don't use JavaScript detection. I just use a number of rules that validate each comment on the server. Oh, and I don't use
nofollow.
Points System
I use a points system, which I got the idea from Movable Type, whose spam protection is also based on a points system. For everything in a comment that I like, you get a point. For everything I don't like, you lose a point (or two, or three). If you get a 1 or higher, you've made it on the site as a valid comment. If you get a 0, it's set for moderation and I'll take a look at it. If it's below 0, it's marked as spam and I'll never see it (although I check every couple weeks just in case a legitimate comment needs to be unflagged). If it falls below -10, I don't even bother saving it to the database since it is so obviously spam.
Read more
Traditionally in a CakePHP application, to do static pages you have two options:
- Use the built-in Pages controller and either have all static pages reside in /pages/pagename or set up custom routes.
- Set up an empty action in a controller.
I didn't like either of those options.
With
Nate Abele's help, I wrote up a custom error class that will check to see if a view exists for a missing action or missing controller/action combo. If it does, it'll render that view. This is pretty handy as it means that I can maintain a structure within the view folder that more closely matches the URL structure for the site.
The one current limitation of this right now is that it only accesses the beforeRender call on the AppController and not on a particular controller, if it exists.
Read more
Written by Jonathan Snook · Filed Under design corner | Comments Off