I would try putting your code as this instead: [code] if ($years >= 1) { $str.="{$years} years "; } if ($weeks >= 1) { $str.="{$weeks} weeks "; } if ($days >= 1) { $str.="{$days} days "; } if ($hrs >= 1) { $str.="{$hrs} hours "; } if ($mins >= 1) { $str.="{$mins}"; } // Checks if there are only seconds. if ($years < 1 && $weeks < 1 && $days < 1 && hrs < 1 && mins < 1) {$str = "00";} if ($secs >= 10) { $str.=":{$secs}"; } if ($secs < 10) { $str.=":0{$secs}"; } [/code] This will first work as you wrote it. When it reaches the comment, it checks to see if there are no years, weeks, days, hours or minutes. If there are not, it will set $str to "00" before finishing the script (then the seconds and colon will be added after the 00, which is what you wanted). If there are any of the above, it will do nothing and proceed as it normally would. Hope this helps.