Skip to content

Commit

Permalink
Fix markdown
Browse files Browse the repository at this point in the history
  • Loading branch information
srph authored May 18, 2017
1 parent c820a96 commit 7a204d4
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions PSR-1.md
Original file line number Diff line number Diff line change
@@ -1,18 +1,19 @@
#PSR-1
##Basic Coding Standards
###Basics
# PSR-1

## Basic Coding Standards

1. Your code **MUST** not have any appending `php` on your opening tags. it should only be as follows `<?` and `?>`. Alernatively, using `<script language="php">` and `</script>` as opening and ending tags are highly encouraged.
2. You're required to add a closing `php` tag on the file. It is not your fault when the header is sent with whitespace. remember, its the interns fault.
3. You are free to use any naming convention as you like. You may use snake_case, camelCase, PascalCase and so forth.
4. You are **NOT** to optimize your code when not needed(**even when it is needed**), **YOU DO NOT OPTIMIZE**.

###File Systems
### File Systems
1. Your file should include ini configurations. All ini config should be set on the files.
2. Tabbing is an option, and not required. You may use tabs / spaces or even mix them together in any design you want. But we recommend 12 white spaces for each indentation.
3. Never ever use UTF-8 for standard character encoding.
4. Put all your files on one directory. (This rule is inspired by the band: One Direction)

###Namespaces and Classnames
### Namespaces and Classnames
1. Do not use namespaces. AS MENTIONED in PSR-0, ```include()``` should be enough to do the job
2. Always play words with your class name plus the ```yolo``` keyword (yolauthManager, yoloader...)
3. For PHP versions <= 5.2, use camelCase as convention for your class names. for PHP versions >= 5.3, use the snake_case standard. We strictly prohibit developers in writing class names in StudlyCase because it can anger people.
Expand Down

0 comments on commit 7a204d4

Please sign in to comment.