Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

javascript multiple cases

switch (varName)
{
   case "afshin":
   case "saeed":
   case "larry": 
       alert('Hey');
       break;

   default: 
       alert('Default case');
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #javascript #multiple #cases
ADD COMMENT
Topic
Name
4+3 =