Posts Tagged ‘web dev’

Radio Buttons not Showing Checked in FireFox

Friday, February 6th, 2009

In the process of building a WordPress plugin that I’m sure will sweep the nation ;-)  , I came across a really annoying FireFox bug with Radio Buttons.  The problem is that if you two groups of Radio Buttons (say 3 buttons in each group) and you set one button as Checked in each group, sometimes, the button in the first group won’t show up as Checked.  Arrrgghhhh! (more…)

Popularity: 25%

PhotoSmash Galleries WordPress Plugin Released

Monday, January 19th, 2009

UPDATE:  7/12/2009 -PhotoSmash 0.3 has been released.  Its new homepage is just getting started, so you might need to browse below if you don’t find what you looking for over at Smashly.net.  Thanks for your patience!

Release Candidate 2 version 0.2.996 (RC3 for 0.3.00) now available at WordPress.

(more…)

Popularity: 100%

OOP PHP: What is the Double Colon in Objects/Classes for?

Friday, January 16th, 2009

phpI happen to be the only PHP programmer that I know, so it’s hard to ask your buddy what the heck that :: is used for in some OO PHP programs.  I know you could post it on a forum and get the answer, but I never did.  And Google wasn’t really forth coming when you put :: in a search.  Finally I found it in the PHP documentation:  check out Scope Resolution Operator (::).  In short, it’s used to access Static or Constant members of a class.  Here’s a brief example:

(more…)

Popularity: 13%

PHP: Using Switch to test Multiple Conditions

Sunday, August 3rd, 2008

Ok, so maybe this is common knowledge, but I still felt a little clever when I figured out this trick.  The situation was that I wanted to test a bunch of different conditions to figure out which time category a date falls into.  It would be fairly simple to do with a bunch of if…then…else’s, but really ugly.  Here’s the trick I came up with…use switch(true), and then set up your cases to evaluate to true or false. Here’s some example code:

(more…)

Popularity: 9%