Instead of:
Code:
if ($var == 10) {
// do something
} elseif ($var == 15) {
// do something else
} elseif ($var == 20) {
// do some other thing
} else {
// do the default
}
You can use the switch structure:
Code:
switch ($var) {
case '10':
// do something
break;
case '15':
// do something else
break;
case '20':
// do some other thing
break;
default:
// do the default
}