Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
en:entwickler:programmierrichtlinien [2016/12/03 14:39] – [Defining functions] ximexen:entwickler:programmierrichtlinien [2021/11/15 14:28] (current) fasse
Line 27: Line 27:
   * while   * while
   * switch   * switch
-It should be ensured that the braces are always at the height of the associated control structure in a separate line!+The open parenthesis is set after the control structure with a space between. The closing parenthesis is always set at the height of the control structure.
  
 Here is an example of a nested if statement: Here is an example of a nested if statement:
-<code php>if ((condition1) && (condition2)) +<code php>if ((condition1) && (condition2)) {
-{+
     action1;     action1;
-    if (condition3) +    if (condition3) {
-    {+
         action2;         action2;
     }     }
-} +} elseif ((condition4) or (condition5)) {
-elseif ((condition4) or (condition5)) +
-{+
     action3;     action3;
     action4;     action4;
-} +} else {
-else +
-{+
     defaultaction;     defaultaction;
 }</code> }</code>
Line 53: Line 47:
  
 Here is an example of a switch / case statement: Here is an example of a switch / case statement:
-<code php>switch (condition) +<code php>switch (condition) {
-{+
     case 1:     case 1:
         action1;         action1;
Line 129: Line 122:
  </code>  </code>
  
-===== SVN Requirements ===== +===== Git Requirements ===== 
-When files are checked into SVN, a commit message must be drawn up. In a bugfix the commit message definitely should belong to the associated bow number and a short description of the activities done in the script ...+When files are checked into Git, a commit message must be drawn up. In a bugfix the commit message definitely should belong to the associated issue number e.g. **#123** and a short description of the activities done in the script ...
  
 ===== Name Convention ===== ===== Name Convention =====
  • en/entwickler/programmierrichtlinien.1480772360.txt.gz
  • Last modified: 2016/12/03 14:39
  • by ximex