Thread: case statement
View Single Post
  #3 (permalink)  
Old August 15th, 2003, 06:09 AM
p15ed p15ed is offline
Registered User
Join Date: Aug 2003
Location: , , .
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts


case "D":
case "W":
if ($new_p1<1 OR $new_p1>30) {
$t1_errMsg = "The number of billing cycle days/weeks must be between 1 and 30";

The trick with switch statements is that the Php processor will 'tumble' through each case until it finds a 'break' keyword. thus many cases can execute the same code if placed one after another.

Reply With Quote