Web Hosting Talk







View Full Version : Simple php question, do switch numbers have to be in order?


lexington
01-02-2007, 11:06 PM
I tried looking up this info and didn't see any mention of it. I ask since I am commenting out some switch commands numbered one through 19 and I wonder if that would cause a problem if it skips from 14 to 17 for example. I tested this and everything seemed to work fine but I wanted to make sure it was not causing a problem I am not aware of. Thanks.

brendandonhu
01-02-2007, 11:09 PM
You can put them in any order. PHP will look at them from top to bottom.

lexington
01-02-2007, 11:43 PM
Thanks for the help :)

brendandonhu
01-03-2007, 12:44 AM
No problem :)