diff --git a/client/src/pages/guide/english/php/switch/index.md b/client/src/pages/guide/english/php/switch/index.md index 4d4ef2d908..a7d9be04ca 100644 --- a/client/src/pages/guide/english/php/switch/index.md +++ b/client/src/pages/guide/english/php/switch/index.md @@ -19,7 +19,8 @@ In PHP, the `Switch` statement is very similar to the Javascript `Switch` statem echo "i is camp"; break; default: - echo "i is freecodecamp"; + echo "i is freecodecamp"; + break; } ``` @@ -27,5 +28,61 @@ In PHP, the `Switch` statement is very similar to the Javascript `Switch` statem ### Break The `break;` statement exits the switch and goes on to run the rest of the application's code. If you do not use the `break;` statement you may end up running mulitple cases and statements, sometimes this may be desired in which case you should not include the `break;` statement. +An example of this behavior can be seen below: + +``` +php.net docs Switch +* [php.net docs Switch](https://secure.php.net/manual/en/control-structures.switch.php")