Forum Moderators: coopster
If it is an array you need to use then use something like $array['key']
Here's your example with a variable name:
<?php switch ($VAR_NAME) {
case 'FOO':
echo 'wooo';
break;
default: echo 'whoo';
}
?>
But if you really need the 2 then you should be calling the [VAR_NAME] from where it was originally assigned (a proper PHP variable). A template will parse and replace it's own variables in a page, and I doubt that it will do it and allow PHP to be used at the same time... it wouldn't make sense.
Perhaps we need a bigger picture of what you are trying to achieve, and also what template system you are using.