Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

php switch 2 variables

switch ([$color, $size]) {
    case ['blue', 'small']:
        echo 'blue and small';
    break;

    case ['red', 'large'];
        echo 'red and large';
    break;
}
 
PREVIOUS NEXT
Tagged: #php #switch #variables
ADD COMMENT
Topic
Name
3+6 =