Passed
Push — master ( 2744eb...81ba93 )
by Michael
02:46
created
language/english/modinfo.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -385,7 +385,7 @@
 block discarded – undo
385 385
 
386 386
 //Help
387 387
 define('_MI_SF_DIRNAME', basename(dirname(dirname(__DIR__))));
388
-define('_MI_SF_HELP_HEADER', __DIR__ . '/help/helpheader.tpl');
388
+define('_MI_SF_HELP_HEADER', __DIR__.'/help/helpheader.tpl');
389 389
 define('_MI_SF_BACK_2_ADMIN', 'Back to Administration of ');
390 390
 define('_MI_SF_OVERVIEW', 'Overview');
391 391
 
Please login to merge, or discard this patch.
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -115,7 +115,7 @@  discard block
 block discarded – undo
115 115
 define('_MI_SF_REQUESTINTROMSGDSC', 'Introduction message to be displayed in the Request a Q&A page of the module.');
116 116
 define(
117 117
     '_MI_SF_REQUESTINTROMSGDEF',
118
-       'You did not find the answer to the question you were looking for? No problem! Simply fill the following form in order to request the answer for a new question. The site administrator will review your request and publish this new question in the Open Questions section for someone to answer it!'
118
+        'You did not find the answer to the question you were looking for? No problem! Simply fill the following form in order to request the answer for a new question. The site administrator will review your request and publish this new question in the Open Questions section for someone to answer it!'
119 119
 );
120 120
 
121 121
 define('_MI_SF_OPENINTROMSG', 'Open Questions section introduction message:');
@@ -128,7 +128,7 @@  discard block
 block discarded – undo
128 128
 define('_MI_SF_HELP_PATH_SELECT', "Path of SmartFAQ's help files");
129 129
 define(
130 130
     '_MI_SF_HELP_PATH_SELECT_DSC',
131
-       "SELECT FROM where you would LIKE TO access SmartFAQ's help files. If you downloaded the 'SmartFAQ's Help Package' AND uploaded it IN 'modules/smartfaq/doc/', you can SELECT 'Inside the module'. Alternatively, you can access the module's help file directly from docs.xoops.org by chosing this in the selector. You can also select 'Custom Path' and specify yourself the path of the help files in the next config option 'Custom path of SmartFAQ's help files'"
131
+        "SELECT FROM where you would LIKE TO access SmartFAQ's help files. If you downloaded the 'SmartFAQ's Help Package' AND uploaded it IN 'modules/smartfaq/doc/', you can SELECT 'Inside the module'. Alternatively, you can access the module's help file directly from docs.xoops.org by chosing this in the selector. You can also select 'Custom Path' and specify yourself the path of the help files in the next config option 'Custom path of SmartFAQ's help files'"
132 132
 );
133 133
 
134 134
 define('_MI_SF_HELP_PATH_CUSTOM', "Custom path of SmartFAQ's help files");
@@ -351,7 +351,7 @@  discard block
 block discarded – undo
351 351
 define('_MI_SF_DIR_ATTACHMENT', 'Attachments physical path.');
352 352
 define(
353 353
     '_MI_SF_DIR_ATTACHMENT_DESC',
354
-       "Physical path only needs to be set from your xoops root and not before, for example you may have attachments uploaded to www.yoururl.com/uploads/newbb the path entered would then be '/uploads/newbb' never include a trailing slash '/' the thumbnails path becomes '/uploads/newbb/thumbs'"
354
+        "Physical path only needs to be set from your xoops root and not before, for example you may have attachments uploaded to www.yoururl.com/uploads/newbb the path entered would then be '/uploads/newbb' never include a trailing slash '/' the thumbnails path becomes '/uploads/newbb/thumbs'"
355 355
 );
356 356
 define('_MI_SF_PATH_MAGICK', 'Path for ImageMagick');
357 357
 define('_MI_SF_PATH_MAGICK_DESC', "Usually it is '/usr/bin/X11'. Leave it BLANK if you do not have ImageMagicK installed or for autodetecting.");
Please login to merge, or discard this patch.
comment_delete.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -6,5 +6,5 @@
 block discarded – undo
6 6
  * Licence: GNU
7 7
  */
8 8
 
9
-include __DIR__ . '/../../mainfile.php';
10
-require_once XOOPS_ROOT_PATH . '/include/comment_delete.php';
9
+include __DIR__.'/../../mainfile.php';
10
+require_once XOOPS_ROOT_PATH.'/include/comment_delete.php';
Please login to merge, or discard this patch.
open_index.php 2 patches
Indentation   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -116,13 +116,13 @@
 block discarded – undo
116 116
 // Language constants
117 117
 $moduleName =& $myts->displayTarea($xoopsModule->getVar('name'));
118 118
 $xoopsTpl->assign([
119
-                      'lang_on'       => _MD_SF_ON,
120
-                      'lang_postedby' => _MD_SF_POSTEDBY,
121
-                      'lang_total'    => $totalQnasOnPage,
122
-                      'lang_faq'      => _MD_SF_FAQ,
123
-                      'lang_datesub'  => _MD_SF_DATESUB,
124
-                      'lang_hits'     => _MD_SF_HITS
125
-                  ]);
119
+                        'lang_on'       => _MD_SF_ON,
120
+                        'lang_postedby' => _MD_SF_POSTEDBY,
121
+                        'lang_total'    => $totalQnasOnPage,
122
+                        'lang_faq'      => _MD_SF_FAQ,
123
+                        'lang_datesub'  => _MD_SF_DATESUB,
124
+                        'lang_hits'     => _MD_SF_HITS
125
+                    ]);
126 126
 
127 127
 $moduleName =& $myts->displayTarea($xoopsModule->getVar('name'));
128 128
 $xoopsTpl->assign('lang_mainhead', sprintf(_MD_SF_OPEN_WELCOME, $xoopsConfig['sitename']));
Please login to merge, or discard this patch.
Spacing   +16 added lines, -16 removed lines patch added patch discarded remove patch
@@ -10,7 +10,7 @@  discard block
 block discarded – undo
10 10
 use XoopsModules\Smartfaq\Constants;
11 11
 
12 12
 
13
-require_once __DIR__ . '/header.php';
13
+require_once __DIR__.'/header.php';
14 14
 
15 15
 global $xoopsConfig, $xoopsModule;
16 16
 /** @var Smartfaq\Helper $helper */
@@ -49,8 +49,8 @@  discard block
 block discarded – undo
49 49
 
50 50
 $GLOBALS['xoopsOption']['template_main'] = 'smartfaq_index.tpl';
51 51
 
52
-require_once XOOPS_ROOT_PATH . '/header.php';
53
-require_once __DIR__ . '/footer.php';
52
+require_once XOOPS_ROOT_PATH.'/header.php';
53
+require_once __DIR__.'/footer.php';
54 54
 
55 55
 //get all categories for future reference
56 56
 $allcategories = $categoryHandler->getObjects(null, true);
@@ -72,11 +72,11 @@  discard block
 block discarded – undo
72 72
             if (isset($totalQnas[$subcat_id]) && $totalQnas[$subcat_id] > 0) {
73 73
                 if (isset($last_qnaObj[$subcat_id])) {
74 74
                     $subcat->setVar('last_faqid', $last_qnaObj[$subcat_id]->getVar('faqid'));
75
-                    $subcat->setVar('last_question_link', "<a href='faq.php?faqid=" . $last_qnaObj[$subcat_id]->getVar('faqid') . "'>" . $last_qnaObj[$subcat_id]->question(50) . '</a>');
75
+                    $subcat->setVar('last_question_link', "<a href='faq.php?faqid=".$last_qnaObj[$subcat_id]->getVar('faqid')."'>".$last_qnaObj[$subcat_id]->question(50).'</a>');
76 76
                 }
77 77
                 $subcat->setVar('faqcount', $totalQnas[$subcat_id]);
78 78
                 $categories[$cat_id]['subcats'][$subcat_id] = $subcat->toArray(null, true);
79
-                $total                                      += $totalQnas[$subcat_id];
79
+                $total += $totalQnas[$subcat_id];
80 80
             }
81 81
         }
82 82
     }
@@ -108,7 +108,7 @@  discard block
 block discarded – undo
108 108
         }
109 109
 
110 110
         $memberHandler = xoops_getHandler('member');
111
-        $users         = $memberHandler->getUsers(new \Criteria('uid', '(' . implode(',', array_keys($userids)) . ')', 'IN'), true);
111
+        $users         = $memberHandler->getUsers(new \Criteria('uid', '('.implode(',', array_keys($userids)).')', 'IN'), true);
112 112
         for ($i = 0; $i < $totalQnasOnPage; ++$i) {
113 113
             $faq = $faqsObj[$i]->toArray(null, $allcategories);
114 114
 
@@ -121,7 +121,7 @@  discard block
 block discarded – undo
121 121
     }
122 122
 }
123 123
 // Language constants
124
-$moduleName =& $myts->displayTarea($xoopsModule->getVar('name'));
124
+$moduleName = & $myts->displayTarea($xoopsModule->getVar('name'));
125 125
 $xoopsTpl->assign([
126 126
                       'lang_on'       => _MD_SF_ON,
127 127
                       'lang_postedby' => _MD_SF_POSTEDBY,
@@ -131,7 +131,7 @@  discard block
 block discarded – undo
131 131
                       'lang_hits'     => _MD_SF_HITS
132 132
                   ]);
133 133
 
134
-$moduleName =& $myts->displayTarea($xoopsModule->getVar('name'));
134
+$moduleName = & $myts->displayTarea($xoopsModule->getVar('name'));
135 135
 $xoopsTpl->assign('lang_mainhead', sprintf(_MD_SF_OPEN_WELCOME, $xoopsConfig['sitename']));
136 136
 $xoopsTpl->assign('lang_mainintro', $myts->displayTarea($helper->getConfig('openquestionintromsg'), 1));
137 137
 $xoopsTpl->assign('lang_total', _MD_SF_TOTAL_QUESTIONS);
@@ -139,7 +139,7 @@  discard block
 block discarded – undo
139 139
 $xoopsTpl->assign('lang_description', _MD_SF_DESCRIPTION);
140 140
 $xoopsTpl->assign('lang_category', _MD_SF_CATEGORY);
141 141
 $xoopsTpl->assign('sectionname', $moduleName);
142
-$xoopsTpl->assign('whereInSection', "<a href='index.php'>" . $moduleName . '</a> > ' . _MD_SF_OPEN_SECTION);
142
+$xoopsTpl->assign('whereInSection', "<a href='index.php'>".$moduleName.'</a> > '._MD_SF_OPEN_SECTION);
143 143
 
144 144
 $xoopsTpl->assign('displayFull', false);
145 145
 $xoopsTpl->assign('displaylastfaqs', $helper->getConfig('displaylastfaqs'));
@@ -155,25 +155,25 @@  discard block
 block discarded – undo
155 155
 $xoopsTpl->assign('lang_category', _MD_SF_CATEGORY);
156 156
 
157 157
 // Category Navigation Bar
158
-require_once XOOPS_ROOT_PATH . '/class/pagenav.php';
158
+require_once XOOPS_ROOT_PATH.'/class/pagenav.php';
159 159
 $pagenav = new \XoopsPageNav($totalCategories, $helper->getConfig('catperpage'), $catstart, 'catstart', '');
160 160
 if (1 == $helper->getConfig('useimagenavpage')) {
161
-    $xoopsTpl->assign('catnavbar', '<div style="text-align:right;">' . $pagenav->renderImageNav() . '</div>');
161
+    $xoopsTpl->assign('catnavbar', '<div style="text-align:right;">'.$pagenav->renderImageNav().'</div>');
162 162
 } else {
163
-    $xoopsTpl->assign('catnavbar', '<div style="text-align:right;">' . $pagenav->renderNav() . '</div>');
163
+    $xoopsTpl->assign('catnavbar', '<div style="text-align:right;">'.$pagenav->renderNav().'</div>');
164 164
 }
165 165
 
166 166
 // FAQ Navigation Bar
167 167
 $pagenav = new \XoopsPageNav($totalFaqs, $helper->getConfig('indexperpage'), $start, 'start', '');
168 168
 if (1 == $helper->getConfig('useimagenavpage')) {
169
-    $xoopsTpl->assign('navbar', '<div style="text-align:right;">' . $pagenav->renderImageNav() . '</div>');
169
+    $xoopsTpl->assign('navbar', '<div style="text-align:right;">'.$pagenav->renderImageNav().'</div>');
170 170
 } else {
171
-    $xoopsTpl->assign('navbar', '<div style="text-align:right;">' . $pagenav->renderNav() . '</div>');
171
+    $xoopsTpl->assign('navbar', '<div style="text-align:right;">'.$pagenav->renderNav().'</div>');
172 172
 }
173 173
 
174 174
 // Page Title Hack by marcan
175 175
 $module_name = $myts->htmlSpecialChars($xoopsModule->getVar('name'));
176
-$xoopsTpl->assign('xoops_pagetitle', $module_name . ' - ' . $category->getVar('name'));
176
+$xoopsTpl->assign('xoops_pagetitle', $module_name.' - '.$category->getVar('name'));
177 177
 // End Page Title Hack by marcan
178 178
 
179
-require_once XOOPS_ROOT_PATH . '/footer.php';
179
+require_once XOOPS_ROOT_PATH.'/footer.php';
Please login to merge, or discard this patch.
footer.php 2 patches
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -15,12 +15,12 @@
 block discarded – undo
15 15
 $xoopsTpl->assign('isAdmin', $isAdmin);
16 16
 
17 17
 $xoopsTpl->assign([
18
-                      'lang_on'       => _MD_SF_ON,
19
-                      'lang_postedby' => _MD_SF_POSTEDBY,
20
-                      'lang_faq'      => _MD_SF_QUESTION,
21
-                      'lang_datesub'  => _MD_SF_DATESUB,
22
-                      'lang_hits'     => _MD_SF_HITS
23
-                  ]);
18
+                        'lang_on'       => _MD_SF_ON,
19
+                        'lang_postedby' => _MD_SF_POSTEDBY,
20
+                        'lang_faq'      => _MD_SF_QUESTION,
21
+                        'lang_datesub'  => _MD_SF_DATESUB,
22
+                        'lang_hits'     => _MD_SF_HITS
23
+                    ]);
24 24
 $xoopsTpl->assign('sectionname', $myts->displayTarea($xoopsModule->getVar('name')));
25 25
 
26 26
 $xoopsTpl->assign('modulename', $xoopsModule->dirname());
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -13,7 +13,7 @@  discard block
 block discarded – undo
13 13
 $uid     = $xoopsUser ? $xoopsUser->getVar('uid') : 0;
14 14
 $isAdmin = (Smartfaq\Utility::userIsAdmin() || Smartfaq\Utility::hasModerator());
15 15
 
16
-$xoopsTpl->assign('sf_adminpage', "<a href='" . XOOPS_URL . "/modules/smartfaq/admin/index.php'>" . _MD_SF_ADMIN_PAGE . '</a>');
16
+$xoopsTpl->assign('sf_adminpage', "<a href='".XOOPS_URL."/modules/smartfaq/admin/index.php'>"._MD_SF_ADMIN_PAGE.'</a>');
17 17
 $xoopsTpl->assign('isAdmin', $isAdmin);
18 18
 
19 19
 $xoopsTpl->assign([
@@ -36,4 +36,4 @@  discard block
 block discarded – undo
36 36
 
37 37
 $xoopsTpl->assign('ref_smartfaq', 'SmartFAQ is developed by The SmartFactory (http://www.smartfactory.ca), a division of InBox Solutions (http://www.inboxsolutions.net)');
38 38
 
39
-$xoopsTpl->assign('xoops_module_header', "<link rel='stylesheet' type='text/css' href='" . XOOPS_URL . "/modules/smartfaq/assets/css/smartfaq.css'>");
39
+$xoopsTpl->assign('xoops_module_header', "<link rel='stylesheet' type='text/css' href='".XOOPS_URL."/modules/smartfaq/assets/css/smartfaq.css'>");
Please login to merge, or discard this patch.
include/notification.inc.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -35,22 +35,22 @@
 block discarded – undo
35 35
 
36 36
     if ('category' === $category) {
37 37
         // Assume we have a valid category id
38
-        $sql          = 'SELECT name FROM ' . $xoopsDB->prefix('smartfaq_categories') . ' WHERE categoryid  = ' . $item_id;
38
+        $sql          = 'SELECT name FROM '.$xoopsDB->prefix('smartfaq_categories').' WHERE categoryid  = '.$item_id;
39 39
         $result       = $xoopsDB->queryF($sql); // TODO: error check
40 40
         $result_array = $xoopsDB->fetchArray($result);
41 41
         $item['name'] = $result_array['name'];
42
-        $item['url']  = XOOPS_URL . '/modules/' . $module->getVar('dirname') . '/category.php?categoryid=' . $item_id;
42
+        $item['url']  = XOOPS_URL.'/modules/'.$module->getVar('dirname').'/category.php?categoryid='.$item_id;
43 43
 
44 44
         return $item;
45 45
     }
46 46
 
47 47
     if ('faq' === $category) {
48 48
         // Assume we have a valid story id
49
-        $sql          = 'SELECT question FROM ' . $xoopsDB->prefix('smartfaq_faq') . ' WHERE faqid = ' . $item_id;
49
+        $sql          = 'SELECT question FROM '.$xoopsDB->prefix('smartfaq_faq').' WHERE faqid = '.$item_id;
50 50
         $result       = $xoopsDB->queryF($sql); // TODO: error check
51 51
         $result_array = $xoopsDB->fetchArray($result);
52 52
         $item['name'] = $result_array['question'];
53
-        $item['url']  = XOOPS_URL . '/modules/' . $module->getVar('dirname') . '/faq.php?faqid=' . $item_id;
53
+        $item['url']  = XOOPS_URL.'/modules/'.$module->getVar('dirname').'/faq.php?faqid='.$item_id;
54 54
 
55 55
         return $item;
56 56
     }
Please login to merge, or discard this patch.
admin/answer.php 2 patches
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -114,18 +114,18 @@
 block discarded – undo
114 114
     foreach ($proposed_answers as $proposed_answer) {
115 115
         if (Constants::SF_STATUS_NEW_ANSWER == $faqObj->status()) {
116 116
             $merge   = "<a href='faq.php?op=merge&amp;faqid="
117
-                       . $faqObj->faqid()
118
-                       . '&amp;answerid='
119
-                       . $proposed_answer->answerid()
120
-                       . "'><img src='"
121
-                       . XOOPS_URL
122
-                       . '/modules/'
123
-                       . $xoopsModule->dirname()
124
-                       . "/assets/images/icon/merge.gif' title='"
125
-                       . _AM_SF_FAQ_MERGE
126
-                       . "' alt='"
127
-                       . _AM_SF_FAQ_MERGE
128
-                       . "'></a>&nbsp;";
117
+                        . $faqObj->faqid()
118
+                        . '&amp;answerid='
119
+                        . $proposed_answer->answerid()
120
+                        . "'><img src='"
121
+                        . XOOPS_URL
122
+                        . '/modules/'
123
+                        . $xoopsModule->dirname()
124
+                        . "/assets/images/icon/merge.gif' title='"
125
+                        . _AM_SF_FAQ_MERGE
126
+                        . "' alt='"
127
+                        . _AM_SF_FAQ_MERGE
128
+                        . "'></a>&nbsp;";
129 129
             $approve = "<a href='answer.php?op=selectanswer&amp;faqid=" . $faqid . '&amp;answerid=' . $proposed_answer->answerid() . "'><img src='" . $pathIcon16 . '/on.png' . "' title='" . _AM_SF_FAQ_APPROVE_NEW_ANSWER . "' alt='" . _AM_SF_APPROVESUB . "'></a>";
130 130
         }
131 131
         $modify = "<a href='faq.php?op=mod&amp;faqid=" . $faqObj->faqid() . '&amp;answerid=' . $proposed_answer->answerid() . "'><img src='" . $pathIcon16 . '/edit.png' . "' title='" . _AM_SF_FAQ_REVIEW . "' alt='" . _AM_SF_FAQ_REVIEW . "'></a>&nbsp;";
Please login to merge, or discard this patch.
Spacing   +27 added lines, -27 removed lines patch added patch discarded remove patch
@@ -12,7 +12,7 @@  discard block
 block discarded – undo
12 12
 /** @var Smartfaq\Helper $helper */
13 13
 $helper = Smartfaq\Helper::getInstance();
14 14
 
15
-require_once __DIR__ . '/admin_header.php';
15
+require_once __DIR__.'/admin_header.php';
16 16
 
17 17
 $op = '';
18 18
 
@@ -37,7 +37,7 @@  discard block
 block discarded – undo
37 37
     /** @var Smartfaq\Helper $helper */
38 38
     $helper = Smartfaq\Helper::getInstance();
39 39
 
40
-    require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
40
+    require_once XOOPS_ROOT_PATH.'/class/xoopsformloader.php';
41 41
 
42 42
     // Creating the FAQ object
43 43
     $faqObj = new Smartfaq\Faq($faqid);
@@ -74,9 +74,9 @@  discard block
 block discarded – undo
74 74
     $official_answer = $faqObj->answer();
75 75
 
76 76
     Smartfaq\Utility::collapsableBar('bottomtable', 'bottomtableicon');
77
-    echo "<img id='bottomtableicon' src=" . XOOPS_URL . '/modules/' . $xoopsModule->dirname() . "/assets/images/icon/close12.gif alt=''></a>&nbsp;" . _AM_SF_SUBMITTED_ANSWER . '</h3>';
77
+    echo "<img id='bottomtableicon' src=".XOOPS_URL.'/modules/'.$xoopsModule->dirname()."/assets/images/icon/close12.gif alt=''></a>&nbsp;"._AM_SF_SUBMITTED_ANSWER.'</h3>';
78 78
     echo "<div id='bottomtable'>";
79
-    echo '<span style="color: #567; margin: 3px 0 12px 0; font-size: small; display: block; ">' . _AM_SF_SUBMITTED_ANSWER_INFO . '</span>';
79
+    echo '<span style="color: #567; margin: 3px 0 12px 0; font-size: small; display: block; ">'._AM_SF_SUBMITTED_ANSWER_INFO.'</span>';
80 80
 
81 81
     $proposed_answers = $answerHandler->getAllAnswers($faqid, Constants::SF_AN_STATUS_PROPOSED);
82 82
 
@@ -86,31 +86,31 @@  discard block
 block discarded – undo
86 86
 
87 87
     echo "<table width='100%' cellspacing=1 cellpadding=3 border=0 class = outer>
88 88
             <tr>
89
-              <td class='head' width='100px'>" . _AM_SF_CATEGORY . "</td>
90
-              <td class='even'>" . $categoryObj->name() . "</td>
89
+              <td class='head' width='100px'>" . _AM_SF_CATEGORY."</td>
90
+              <td class='even'>" . $categoryObj->name()."</td>
91 91
             </tr>
92 92
             <tr>
93
-              <td class='head' width='100px'>" . _AM_SF_QUESTION . "</td>
94
-              <td class='even'>" . $faqObj->question() . '</td>
93
+              <td class='head' width='100px'>" . _AM_SF_QUESTION."</td>
94
+              <td class='even'>" . $faqObj->question().'</td>
95 95
             </tr>';
96 96
     if ($official_answer) {
97 97
         echo "
98 98
             <tr>
99
-              <td class='head' width='100px'>" . _AM_SF_ANSWER_OFFICIAL . "</td>
100
-              <td class='even'>" . $official_answer->answer() . '</td>
99
+              <td class='head' width='100px'>" . _AM_SF_ANSWER_OFFICIAL."</td>
100
+              <td class='even'>" . $official_answer->answer().'</td>
101 101
             </tr>';
102 102
     }
103 103
     echo "</table><br>\n";
104 104
 
105 105
     echo "<table width='100%' cellspacing=1 cellpadding=3 border=0 class = outer>";
106 106
     echo '<tr>';
107
-    echo "<th width='40' class='bg3' align='center'><b>" . _AM_SF_ARTID . '</b></td>';
108
-    echo "<th class='bg3' class='bg3' align='center'><b>" . _AM_SF_ANSWER . '</b></td>';
107
+    echo "<th width='40' class='bg3' align='center'><b>"._AM_SF_ARTID.'</b></td>';
108
+    echo "<th class='bg3' class='bg3' align='center'><b>"._AM_SF_ANSWER.'</b></td>';
109 109
 
110
-    echo "<th width='90' class='bg3' align='center'><b>" . _AM_SF_ANSWERED . '</b></td>';
110
+    echo "<th width='90' class='bg3' align='center'><b>"._AM_SF_ANSWERED.'</b></td>';
111 111
 
112
-    echo "<th width='180' class='bg3' align='center'><b>" . _AM_SF_CREATED . '</b></td>';
113
-    echo "<th width='120' class='bg3' align='center'><b>" . _AM_SF_ACTION . '</b></td>';
112
+    echo "<th width='180' class='bg3' align='center'><b>"._AM_SF_CREATED.'</b></td>';
113
+    echo "<th width='120' class='bg3' align='center'><b>"._AM_SF_ACTION.'</b></td>';
114 114
     echo '</tr>';
115 115
 
116 116
     $merge   = '';
@@ -118,7 +118,7 @@  discard block
 block discarded – undo
118 118
     $approve = '';
119 119
     foreach ($proposed_answers as $proposed_answer) {
120 120
         if (Constants::SF_STATUS_NEW_ANSWER == $faqObj->status()) {
121
-            $merge   = "<a href='faq.php?op=merge&amp;faqid="
121
+            $merge = "<a href='faq.php?op=merge&amp;faqid="
122 122
                        . $faqObj->faqid()
123 123
                        . '&amp;answerid='
124 124
                        . $proposed_answer->answerid()
@@ -131,19 +131,19 @@  discard block
 block discarded – undo
131 131
                        . "' alt='"
132 132
                        . _AM_SF_FAQ_MERGE
133 133
                        . "'></a>&nbsp;";
134
-            $approve = "<a href='answer.php?op=selectanswer&amp;faqid=" . $faqid . '&amp;answerid=' . $proposed_answer->answerid() . "'><img src='" . $pathIcon16 . '/on.png' . "' title='" . _AM_SF_FAQ_APPROVE_NEW_ANSWER . "' alt='" . _AM_SF_APPROVESUB . "'></a>";
134
+            $approve = "<a href='answer.php?op=selectanswer&amp;faqid=".$faqid.'&amp;answerid='.$proposed_answer->answerid()."'><img src='".$pathIcon16.'/on.png'."' title='"._AM_SF_FAQ_APPROVE_NEW_ANSWER."' alt='"._AM_SF_APPROVESUB."'></a>";
135 135
         }
136
-        $modify = "<a href='faq.php?op=mod&amp;faqid=" . $faqObj->faqid() . '&amp;answerid=' . $proposed_answer->answerid() . "'><img src='" . $pathIcon16 . '/edit.png' . "' title='" . _AM_SF_FAQ_REVIEW . "' alt='" . _AM_SF_FAQ_REVIEW . "'></a>&nbsp;";
137
-        $delete = "<a href='answer.php?op=del&amp;faqid=" . $faqObj->faqid() . '&amp;answerid=' . $proposed_answer->answerid() . "'><img src='" . $pathIcon16 . '/delete.png' . "' title='" . _AM_SF_DELETESUBM . "' alt='" . _AM_SF_DELETESUBM . "'></a>";
136
+        $modify = "<a href='faq.php?op=mod&amp;faqid=".$faqObj->faqid().'&amp;answerid='.$proposed_answer->answerid()."'><img src='".$pathIcon16.'/edit.png'."' title='"._AM_SF_FAQ_REVIEW."' alt='"._AM_SF_FAQ_REVIEW."'></a>&nbsp;";
137
+        $delete = "<a href='answer.php?op=del&amp;faqid=".$faqObj->faqid().'&amp;answerid='.$proposed_answer->answerid()."'><img src='".$pathIcon16.'/delete.png'."' title='"._AM_SF_DELETESUBM."' alt='"._AM_SF_DELETESUBM."'></a>";
138 138
         echo '<tr>';
139
-        echo "<td class='head' align='center'>" . $proposed_answer->answerid() . '</td>';
140
-        echo "<td class='even' align='left'>" . $proposed_answer->answer() . '</td>';
139
+        echo "<td class='head' align='center'>".$proposed_answer->answerid().'</td>';
140
+        echo "<td class='even' align='left'>".$proposed_answer->answer().'</td>';
141 141
 
142 142
         //show name of the answer submitter
143 143
         $submitter = Smartfaq\Utility::getLinkedUnameFromId($proposed_answer->uid(), $smartModuleConfig['userealname']);
144
-        echo "<td class='even' align='center'>" . $submitter . '</td>';
144
+        echo "<td class='even' align='center'>".$submitter.'</td>';
145 145
 
146
-        echo "<td class='even' align='center'>" . $proposed_answer->datesub() . '</td>';
146
+        echo "<td class='even' align='center'>".$proposed_answer->datesub().'</td>';
147 147
         echo "<td class='even' align='center'> $merge $modify $approve $delete </td>";
148 148
         echo '</tr>';
149 149
     }
@@ -155,7 +155,7 @@  discard block
 block discarded – undo
155 155
 switch ($op) {
156 156
     case 'mod':
157 157
         xoops_cp_header();
158
-        require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
158
+        require_once XOOPS_ROOT_PATH.'/class/xoopsformloader.php';
159 159
         global $xoopsUser, $xoopsUser, $xoopsConfig, $xoopsDB, $xoopsModule, $modify, $myts;
160 160
         $faqid = \Xmf\Request::getInt('faqid', 0, 'GET');
161 161
         editfaq($faqid);
@@ -262,7 +262,7 @@  discard block
 block discarded – undo
262 262
                     $proposed_answers = $answerHandler->getAllAnswers($faqid, Constants::SF_AN_STATUS_PROPOSED);
263 263
                     if (count($proposed_answers) > 0) {
264 264
                         // This question has other proposed answer
265
-                        $redirect_page = 'answer.php?op=mod&faqid=' . $faqid;
265
+                        $redirect_page = 'answer.php?op=mod&faqid='.$faqid;
266 266
                         $redirect_msg  = _AM_SF_ANSWER_REJECTED;
267 267
                     } else {
268 268
                         // The question has no other proposed answer
@@ -286,7 +286,7 @@  discard block
 block discarded – undo
286 286
     default:
287 287
         xoops_cp_header();
288 288
 
289
-        require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
289
+        require_once XOOPS_ROOT_PATH.'/class/xoopsformloader.php';
290 290
         global $xoopsUser, $xoopsUser, $xoopsConfig, $xoopsDB, $xoopsModule;
291 291
         /** @var Smartfaq\Helper $helper */
292 292
         $helper = Smartfaq\Helper::getInstance();
@@ -295,4 +295,4 @@  discard block
 block discarded – undo
295 295
         break;
296 296
 }
297 297
 
298
-require_once __DIR__ . '/admin_footer.php';
298
+require_once __DIR__.'/admin_footer.php';
Please login to merge, or discard this patch.
admin/menu.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -19,47 +19,47 @@
 block discarded – undo
19 19
 $adminmenu[] = [
20 20
     'title' => _MI_SF_HOME,
21 21
     'link'  => 'admin/index.php',
22
-    'icon'  => $pathIcon32 . '/home.png',
22
+    'icon'  => $pathIcon32.'/home.png',
23 23
 ];
24 24
 
25 25
 $adminmenu[] = [
26 26
     'title' => _MI_SF_ADMENU1,
27 27
     'link'  => 'admin/main.php',
28
-    'icon'  => $pathIcon32 . '/manage.png',
28
+    'icon'  => $pathIcon32.'/manage.png',
29 29
 ];
30 30
 
31 31
 $adminmenu[] = [
32 32
     'title' => _MI_SF_ADMENU2,
33 33
     'link'  => 'admin/category.php',
34
-    'icon'  => $pathIcon32 . '/category.png',
34
+    'icon'  => $pathIcon32.'/category.png',
35 35
 ];
36 36
 
37 37
 $adminmenu[] = [
38 38
     'title' => _MI_SF_ADMENU3,
39 39
     'link'  => 'admin/faq.php',
40
-    'icon'  => $pathIcon32 . '/search.png',
40
+    'icon'  => $pathIcon32.'/search.png',
41 41
 ];
42 42
 
43 43
 $adminmenu[] = [
44 44
     'title' => _MI_SF_ADMENU4,
45 45
     'link'  => 'admin/question.php',
46
-    'icon'  => $pathIcon32 . '/faq.png',
46
+    'icon'  => $pathIcon32.'/faq.png',
47 47
 ];
48 48
 
49 49
 $adminmenu[] = [
50 50
     'title' => _MI_SF_ADMENU5,
51 51
     'link'  => 'admin/permissions.php',
52
-    'icon'  => $pathIcon32 . '/permissions.png',
52
+    'icon'  => $pathIcon32.'/permissions.png',
53 53
 ];
54 54
 
55 55
 $adminmenu[] = [
56 56
     'title' => _MI_SF_ADMENU8,
57 57
     'link'  => 'admin/import.php',
58
-    'icon'  => $pathIcon32 . '/download.png',
58
+    'icon'  => $pathIcon32.'/download.png',
59 59
 ];
60 60
 
61 61
 $adminmenu[] = [
62 62
     'title' => _MI_SF_ABOUT,
63 63
     'link'  => 'admin/about.php',
64
-    'icon'  => $pathIcon32 . '/about.png',
64
+    'icon'  => $pathIcon32.'/about.png',
65 65
 ];
Please login to merge, or discard this patch.
admin/import.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -8,7 +8,7 @@  discard block
 block discarded – undo
8 8
 
9 9
 use XoopsModules\Smartfaq;
10 10
 
11
-require_once __DIR__ . '/admin_header.php';
11
+require_once __DIR__.'/admin_header.php';
12 12
 
13 13
 $op = 'none';
14 14
 
@@ -25,7 +25,7 @@  discard block
 block discarded – undo
25 25
     case 'importExecute':
26 26
 
27 27
         $importfile      = isset($_POST['importfile']) ? $_POST['importfile'] : 'nonselected';
28
-        $importfile_path = XOOPS_ROOT_PATH . '/modules/smartfaq/admin/' . $importfile . '.php';
28
+        $importfile_path = XOOPS_ROOT_PATH.'/modules/smartfaq/admin/'.$importfile.'.php';
29 29
         if (!file_exists($importfile_path)) {
30 30
             $errs[] = sprintf(_AM_SF_IMPORT_FILE_NOT_FOUND, $importfile_path);
31 31
             $error  = true;
@@ -33,7 +33,7 @@  discard block
 block discarded – undo
33 33
             require_once $importfile_path;
34 34
         }
35 35
         foreach ($msgs as $m) {
36
-            echo $m . '<br>';
36
+            echo $m.'<br>';
37 37
         }
38 38
         echo '<br>';
39 39
         $endMsg = _AM_SF_IMPORT_SUCCESS;
@@ -43,7 +43,7 @@  discard block
 block discarded – undo
43 43
 
44 44
         echo $endMsg;
45 45
         echo '<br><br>';
46
-        echo "<a href='import.php'>" . _AM_SF_IMPORT_BACK . '</a>';
46
+        echo "<a href='import.php'>"._AM_SF_IMPORT_BACK.'</a>';
47 47
         echo '<br><br>';
48 48
         break;
49 49
 
@@ -55,13 +55,13 @@  discard block
 block discarded – undo
55 55
         xoops_cp_header();
56 56
 
57 57
         Smartfaq\Utility::collapsableBar('bottomtable', 'bottomtableicon');
58
-        echo "<img id='bottomtableicon' src=" . XOOPS_URL . '/modules/' . $xoopsModule->dirname() . "/assets/images/icon/close12.gif alt=''></a>&nbsp;" . _AM_SF_IMPORT_TITLE . '</h3>';
58
+        echo "<img id='bottomtableicon' src=".XOOPS_URL.'/modules/'.$xoopsModule->dirname()."/assets/images/icon/close12.gif alt=''></a>&nbsp;"._AM_SF_IMPORT_TITLE.'</h3>';
59 59
         echo "<div id='bottomtable'>";
60
-        echo '<span style="color: #567; margin: 3px 0 12px 0; font-size: small; display: block; ">' . _AM_SF_IMPORT_INFO . '</span>';
60
+        echo '<span style="color: #567; margin: 3px 0 12px 0; font-size: small; display: block; ">'._AM_SF_IMPORT_INFO.'</span>';
61 61
 
62 62
         global $xoopsUser, $xoopsUser, $xoopsConfig, $xoopsDB, $modify, $xoopsModuleConfig, $xoopsModule, $XOOPS_URL, $myts;
63 63
 
64
-        require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
64
+        require_once XOOPS_ROOT_PATH.'/class/xoopsformloader.php';
65 65
 
66 66
         /** @var XoopsModuleHandler $moduleHandler */
67 67
         $moduleHandler = xoops_getHandler('module');
@@ -101,7 +101,7 @@  discard block
 block discarded – undo
101 101
             $sform->display();
102 102
             unset($hidden);
103 103
         } else {
104
-            echo '<span style="color: #567; margin: 3px 0 12px 0; font-weight: bold; font-size: small; display: block; ">' . _AM_SF_IMPORT_NO_MODULE . '</span>';
104
+            echo '<span style="color: #567; margin: 3px 0 12px 0; font-weight: bold; font-size: small; display: block; ">'._AM_SF_IMPORT_NO_MODULE.'</span>';
105 105
         }
106 106
 
107 107
         // End of collapsable bar
@@ -110,4 +110,4 @@  discard block
 block discarded – undo
110 110
         break;
111 111
 }
112 112
 
113
-require_once __DIR__ . '/admin_footer.php';
113
+require_once __DIR__.'/admin_footer.php';
Please login to merge, or discard this patch.
admin/admin_header2.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -6,13 +6,13 @@
 block discarded – undo
6 6
  * Licence: GNU
7 7
  */
8 8
 
9
-require_once __DIR__ . '/../../../mainfile.php';
10
-require_once __DIR__ . '/../../../include/cp_header.php';
11
-require_once XOOPS_ROOT_PATH . '/kernel/module.php';
12
-require_once XOOPS_ROOT_PATH . '/class/xoopstree.php';
13
-require_once XOOPS_ROOT_PATH . '/class/xoopslists.php';
14
-require_once XOOPS_ROOT_PATH . '/class/pagenav.php';
15
-require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
9
+require_once __DIR__.'/../../../mainfile.php';
10
+require_once __DIR__.'/../../../include/cp_header.php';
11
+require_once XOOPS_ROOT_PATH.'/kernel/module.php';
12
+require_once XOOPS_ROOT_PATH.'/class/xoopstree.php';
13
+require_once XOOPS_ROOT_PATH.'/class/xoopslists.php';
14
+require_once XOOPS_ROOT_PATH.'/class/pagenav.php';
15
+require_once XOOPS_ROOT_PATH.'/class/xoopsformloader.php';
16 16
 
17 17
 //require_once XOOPS_ROOT_PATH . '/modules/smartfaq/include/functions.php';
18 18
 //require_once XOOPS_ROOT_PATH . '/modules/smartfaq/class/category.php';
Please login to merge, or discard this patch.