# Basic Coding Standard This section of the standard comprises what should be considered the standard coding elements that are required to ensure a high level of technical interoperability between shared PHP code. The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in [RFC 2119]. [RFC 2119]: http://www.ietf.org/rfc/rfc2119.txt [PSR-0]: https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-0.md [PSR-4]: https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-4-autoloader.md ## 1. Overview - Files MUST use only `` tags or the short-echo `` tags; it MUST NOT use the other tag variations. ### 2.2. Character Encoding PHP code MUST use only UTF-8 without BOM. ### 2.3. Side Effects A file SHOULD declare new symbols (classes, functions, constants, etc.) and cause no other side effects, or it SHOULD execute logic with side effects, but SHOULD NOT do both. The phrase "side effects" means execution of logic not directly related to declaring classes, functions, constants, etc., *merely from including the file*. "Side effects" include but are not limited to: generating output, explicit use of `require` or `include`, connecting to external services, modifying ini settings, emitting errors or exceptions, modifying global or static variables, reading from or writing to a file, and so on. The following is an example of a file with both declarations and side effects; i.e, an example of what to avoid: ~~~php \n"; // declaration function foo() { // function body } ~~~ The following example is of a file that contains declarations without side effects; i.e., an example of what to emulate: ~~~php