Completed
Branch master (3028d7)
by Markus
06:24 queued 03:12
created
view/profile/specific.php 1 patch
Braces   +15 added lines, -6 removed lines patch added patch discarded remove patch
@@ -21,33 +21,42 @@
 block discarded – undo
21 21
 <h3>Questions asked: </h3>
22 22
 <?php if (empty($questions)) : ?>
23 23
     <p>This user hasen't posted any questions yet.</p>
24
-<?php else : ?>
24
+<?php else {
25
+    : ?>
25 26
     <?php foreach ($questions as $question) : ?>
26 27
         <p>
27 28
             <a href="../../forum/question/<?= $question->id ?>"><?= $question->title ?></a>
28 29
         </p>
29
-    <?php endforeach; ?>
30
+    <?php endforeach;
31
+}
32
+?>
30 33
 <?php endif; ?>
31 34
 <h3>Answers posted: </h3>
32 35
 <?php if (empty($answers)) : ?>
33 36
     <p>This user hasn't posted any answers yet.</p>
34
-<?php else: ?>
37
+<?php else {
38
+    : ?>
35 39
     <?php foreach ($answers as $answer) : ?>
36 40
         <p>
37 41
             <a href="../../forum/question/<?= $answer->question_id ?>"><?= $answer->content ?></a>
38 42
         </p>
39
-    <?php endforeach; ?>
43
+    <?php endforeach;
44
+}
45
+?>
40 46
 <?php endif; ?>
41 47
 <?php if (empty($comments)) : ?>
42 48
     <h3>Comments this user have posted: </h3>
43 49
     <p>This user have not posted any comments yet.</p>
44
-<?php else : ?>
50
+<?php else {
51
+    : ?>
45 52
     <h3>Comments you have posted: </h3>
46 53
     <?php foreach ($comments as $comment) : ?>
47 54
         <p>
48 55
             <a href="../../forum/question/<?= $answer->question_id ?>"><?= $comment->content ?></a>
49 56
         </p>
50
-    <?php endforeach; ?>
57
+    <?php endforeach;
58
+}
59
+?>
51 60
 <?php endif; ?>
52 61
 <h3>Comments on answers you have posted: </h3>
53 62
 <?php foreach ($anscomments as $anscomment) : ?>
Please login to merge, or discard this patch.
view/profile/index.php 1 patch
Braces   +20 added lines, -8 removed lines patch added patch discarded remove patch
@@ -26,40 +26,52 @@
 block discarded – undo
26 26
 <h3>Questions you have asked: </h3>
27 27
 <?php if (empty($posts)) : ?>
28 28
     <p>You have not made any posts yet.</p>
29
-<?php else : ?>
29
+<?php else {
30
+    : ?>
30 31
     <?php foreach ($posts as $post) : ?>
31 32
         <p>
32 33
             <a href="forum/question/<?= $post->id ?>"><?= $post->title ?></a>
33 34
         </p>
34
-    <?php endforeach; ?>
35
+    <?php endforeach;
36
+}
37
+?>
35 38
 <?php endif; ?>
36 39
 <h3>Answers you have posted: </h3>
37 40
 <?php if (empty($answers)) : ?>
38 41
     <p>You have not posted any answers yet.</p>
39
-<?php else : ?>
42
+<?php else {
43
+    : ?>
40 44
     <?php foreach ($answers as $answer) : ?>
41 45
         <p>
42 46
             <a href="forum/question/<?= $answer->question_id ?>"><?= $answer->content ?></a>
43 47
         </p>
44
-    <?php endforeach; ?>
48
+    <?php endforeach;
49
+}
50
+?>
45 51
 <?php endif; ?>
46 52
 <h3>Comments you have posted: </h3>
47 53
 <?php if (empty($comments)) : ?>
48 54
     <p>You have not posted any comments yet.</p>
49
-<?php else : ?>
55
+<?php else {
56
+    : ?>
50 57
     <?php foreach ($comments as $comment) : ?>
51 58
         <p>
52 59
             <a href="forum/question/<?= $answer->question_id ?>"><?= $comment->content ?></a>
53 60
         </p>
54
-    <?php endforeach; ?>
61
+    <?php endforeach;
62
+}
63
+?>
55 64
 <?php endif; ?>
56 65
 <h3>Comments on answers you have posted: </h3>
57 66
 <?php if (empty($anscomments)) : ?>
58 67
     <p>You have not made any comments on answers yet.</p>
59
-<?php else : ?>
68
+<?php else {
69
+    : ?>
60 70
     <?php foreach ($anscomments as $anscomment) : ?>
61 71
         <p>
62 72
             <a href="forum/question/<?= $answer->question_id ?>"><?= $anscomment->content ?></a>
63 73
         </p>
64
-    <?php endforeach; ?>
74
+    <?php endforeach;
75
+}
76
+?>
65 77
 <?php endif; ?>
Please login to merge, or discard this patch.
view/forum/specific.php 1 patch
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -40,9 +40,12 @@
 block discarded – undo
40 40
         <p>
41 41
             <a href="../answer/<?= $item->id ?>">Answer this post</a>
42 42
         </p>
43
-    <?php else : ?>
43
+    <?php else {
44
+    : ?>
44 45
         <p>You have to be logged in to answer on a post!</p>
45
-    <?php endif; ?>
46
+    <?php endif;
47
+}
48
+?>
46 49
     <h2>Comments: </h2>
47 50
     <?php foreach ($comments as $comment) : ?>
48 51
         <div class="comments">
Please login to merge, or discard this patch.
src/Forum/Comment.php 1 patch
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -6,15 +6,15 @@
 block discarded – undo
6 6
 class Comment extends ActiveRecordModel
7 7
 {
8 8
     /**
9
-    * @var string $tableName name of the database table.
10
-    */
9
+     * @var string $tableName name of the database table.
10
+     */
11 11
     protected $tableName = "Comment";
12 12
 
13 13
     /**
14
-    * Columns in the table.
15
-    *
16
-    * @var integer $id primary key auto incremented.
17
-    */
14
+     * Columns in the table.
15
+     *
16
+     * @var integer $id primary key auto incremented.
17
+     */
18 18
     public $id;
19 19
     public $content;
20 20
     public $question_id;
Please login to merge, or discard this patch.
src/Forum/AnswerComment.php 1 patch
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -6,15 +6,15 @@
 block discarded – undo
6 6
 class AnswerComment extends ActiveRecordModel
7 7
 {
8 8
     /**
9
-    * @var string $tableName name of the database table.
10
-    */
9
+     * @var string $tableName name of the database table.
10
+     */
11 11
     protected $tableName = "AnswerComment";
12 12
 
13 13
     /**
14
-    * Columns in the table.
15
-    *
16
-    * @var integer $id primary key auto incremented.
17
-    */
14
+     * Columns in the table.
15
+     *
16
+     * @var integer $id primary key auto incremented.
17
+     */
18 18
     public $id;
19 19
     public $content;
20 20
     public $answer_id;
Please login to merge, or discard this patch.