Completed
Push — master ( 5da9ea...eef579 )
by Angel Fernando Quiroz
50:18 queued 17:36
created
src/Chamilo/CoreBundle/Component/Editor/Finder.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@  discard block
 block discarded – undo
31 31
         $this->time  = $this->utime();
32 32
         $this->debug = (isset($opts['debug']) && $opts['debug'] ? true : false);
33 33
         $this->timeout = (isset($opts['timeout']) ? $opts['timeout'] : 0);
34
-        $this->netVolumesSessionKey = !empty($opts['netVolumesSessionKey'])? $opts['netVolumesSessionKey'] : 'elFinderNetVolumes';
34
+        $this->netVolumesSessionKey = !empty($opts['netVolumesSessionKey']) ? $opts['netVolumesSessionKey'] : 'elFinderNetVolumes';
35 35
         $this->callbackWindowURL = (isset($opts['callbackWindowURL']) ? $opts['callbackWindowURL'] : '');
36 36
 
37 37
         // setlocale and global locale regists to elFinder::locale
@@ -46,20 +46,20 @@  discard block
 block discarded – undo
46 46
             $_reqCmd = isset($_req['cmd']) ? $_req['cmd'] : '';
47 47
             foreach ($opts['bind'] as $cmd => $handlers) {
48 48
                 $doRegist = (strpos($cmd, '*') !== false);
49
-                if (! $doRegist) {
49
+                if (!$doRegist) {
50 50
                     $_getcmd = create_function('$cmd', 'list($ret) = explode(\'.\', $cmd);return trim($ret);');
51 51
                     $doRegist = ($_reqCmd && in_array($_reqCmd, array_map($_getcmd, explode(' ', $cmd))));
52 52
                 }
53 53
                 if ($doRegist) {
54
-                    if (! is_array($handlers) || is_object($handlers[0])) {
54
+                    if (!is_array($handlers) || is_object($handlers[0])) {
55 55
                         $handlers = array($handlers);
56 56
                     }
57
-                    foreach($handlers as $handler) {
57
+                    foreach ($handlers as $handler) {
58 58
                         if ($handler) {
59 59
                             if (is_string($handler) && strpos($handler, '.')) {
60 60
                                 list($_domain, $_name, $_method) = array_pad(explode('.', $handler), 3, '');
61 61
                                 if (strcasecmp($_domain, 'plugin') === 0) {
62
-                                    if ($plugin = $this->getPluginInstance($_name, isset($opts['plugin'][$_name])? $opts['plugin'][$_name] : array())
62
+                                    if ($plugin = $this->getPluginInstance($_name, isset($opts['plugin'][$_name]) ? $opts['plugin'][$_name] : array())
63 63
                                         and method_exists($plugin, $_method)) {
64 64
                                         $this->bind($cmd, array($plugin, $_method));
65 65
                                     }
Please login to merge, or discard this patch.
plugin/resubscription/src/HookResubscription.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@
 block discarded – undo
31 31
 
32 32
             $resubscriptionLimit = Resubscription::create()->get('resubscription_limit');
33 33
 
34
-             // Initialize variables as a calendar year by default
34
+                // Initialize variables as a calendar year by default
35 35
             $limitDateFormat = 'Y-01-01';
36 36
             $limitDate = gmdate($limitDateFormat);
37 37
             $resubscriptionOffset = "1 year";
Please login to merge, or discard this patch.
main/webservices/lp.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -581,7 +581,7 @@
 block discarded – undo
581 581
     /*$sessionIdName = isset($params['session_id_name']) ? $params['session_id_name'] : null;
582 582
     $sessionIdValue = isset($params['session_id_value']) ? $params['session_id_value'] : null;*/
583 583
 
584
-     $courseInfo = CourseManager::getCourseInfoFromOriginalId(
584
+        $courseInfo = CourseManager::getCourseInfoFromOriginalId(
585 585
         $courseIdValue,
586 586
         $courseIdName
587 587
     );
Please login to merge, or discard this patch.
main/webservices/user_import/service.php 1 patch
Indentation   +39 added lines, -39 removed lines patch added patch discarded remove patch
@@ -14,45 +14,45 @@
 block discarded – undo
14 14
  */
15 15
 function import_users_from_file($filepath, $security_key) {
16 16
 
17
-	global $_configuration;
18
-
19
-   	$errors_returned = array(
20
-	   	0 => 'success',
21
-	   	1 => 'file import does not exist',
22
-	   	2 => 'no users to import',
23
-	   	3 => 'wrong datas in file',
24
-	   	4 => 'security error'
25
-   	);
26
-
27
-   	// Check whether this script is launch by server and security key is ok.
28
-   	if (empty($_SERVER['REMOTE_ADDR']) || $_SERVER['REMOTE_ADDR'] != $_SERVER['SERVER_ADDR'] || $security_key != $_configuration['security_key']) {
29
-   		return $errors_returned[4];
30
-   	}
31
-
32
-   	// Libraries
33
-   	require_once 'import.lib.php';
34
-
35
-	// Check is users file exists.
36
-	if (!is_file($filepath)) {
37
-		return $errors_returned[1];
38
-	}
39
-
40
-	// Get list of users
41
-	$users = parse_csv_data($filepath);
42
-	if (count($users) == 0) {
43
-		return $errors_returned[2];
44
-	}
45
-
46
-	// Check the datas for each user
47
-	$errors = validate_data($users);
48
-	if (count($errors) > 0) {
49
-		return $errors_returned[3];
50
-	}
51
-
52
-	// Apply modifications in database
53
-	save_data($users);
54
-
55
-   	return $errors_returned[0]; // Import successfull
17
+    global $_configuration;
18
+
19
+        $errors_returned = array(
20
+            0 => 'success',
21
+            1 => 'file import does not exist',
22
+            2 => 'no users to import',
23
+            3 => 'wrong datas in file',
24
+            4 => 'security error'
25
+        );
26
+
27
+        // Check whether this script is launch by server and security key is ok.
28
+        if (empty($_SERVER['REMOTE_ADDR']) || $_SERVER['REMOTE_ADDR'] != $_SERVER['SERVER_ADDR'] || $security_key != $_configuration['security_key']) {
29
+            return $errors_returned[4];
30
+        }
31
+
32
+        // Libraries
33
+        require_once 'import.lib.php';
34
+
35
+    // Check is users file exists.
36
+    if (!is_file($filepath)) {
37
+        return $errors_returned[1];
38
+    }
39
+
40
+    // Get list of users
41
+    $users = parse_csv_data($filepath);
42
+    if (count($users) == 0) {
43
+        return $errors_returned[2];
44
+    }
45
+
46
+    // Check the datas for each user
47
+    $errors = validate_data($users);
48
+    if (count($errors) > 0) {
49
+        return $errors_returned[3];
50
+    }
51
+
52
+    // Apply modifications in database
53
+    save_data($users);
54
+
55
+        return $errors_returned[0]; // Import successfull
56 56
 }
57 57
 
58 58
 $server = new soap_server();
Please login to merge, or discard this patch.
main/admin/add_sessions_to_promotion.php 2 patches
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -197,7 +197,7 @@  discard block
 block discarded – undo
197 197
       <option value = "%">--</option>
198 198
       <?php
199 199
         echo Display :: get_alphabet_options();
200
-      ?>
200
+        ?>
201 201
      </select>
202 202
 </td>
203 203
 <td align="center">&nbsp;</td>
@@ -207,31 +207,31 @@  discard block
 block discarded – undo
207 207
   <td align="center">
208 208
   <div id="content_source">
209 209
       <?php
210
-      if (!($add_type=='multiple')) {
210
+        if (!($add_type=='multiple')) {
211 211
         ?>
212 212
         <input type="text" id="user_to_add" onkeyup="xajax_search_users(this.value,'single')" />
213 213
         <div id="ajax_list_users_single"></div>
214 214
         <?php
215
-      } else {
216
-      ?>
215
+        } else {
216
+        ?>
217 217
       <div id="ajax_list_multiple">
218 218
         <?php echo Display::select('session_not_in_promotion_name',$session_not_in_promotion, '',array('style'=>'width:360px', 'multiple'=>'multiple','id'=>'session_not_in_promotion','size'=>'15px'),false); ?>
219 219
       </div>
220 220
     <?php
221
-      }
222
-     ?>
221
+        }
222
+        ?>
223 223
   </div>
224 224
   </td>
225 225
   <td width="10%" valign="middle" align="center">
226 226
   <?php
227
-  if ($ajax_search) {
228
-  ?>
227
+    if ($ajax_search) {
228
+    ?>
229 229
     <button class="btn btn-default" type="button" onclick="remove_item(document.getElementById('session_in_promotion'))" >
230 230
         <em class="fa fa-arrow-left"></em>
231 231
     </button>
232 232
   <?php
233
-  } else {
234
-  ?>
233
+    } else {
234
+    ?>
235 235
     <button class="btn btn-default" type="button" onclick="moveItem(document.getElementById('session_not_in_promotion'), document.getElementById('session_in_promotion'))" onclick="moveItem(document.getElementById('session_not_in_promotion'), document.getElementById('session_in_promotion'))">
236 236
         <em class="fa fa-arrow-right"></em>
237 237
     </button>
@@ -240,8 +240,8 @@  discard block
 block discarded – undo
240 240
         <em class="fa fa-arrow-left"></em>
241 241
     </button>
242 242
     <?php
243
-  }
244
-  ?>
243
+    }
244
+    ?>
245 245
     <br /><br /><br /><br /><br /><br />
246 246
   </td>
247 247
   <td align="center">
Please login to merge, or discard this patch.
Spacing   +14 added lines, -14 removed lines patch added patch discarded remove patch
@@ -10,7 +10,7 @@  discard block
 block discarded – undo
10 10
 require_once __DIR__.'/../inc/global.inc.php';
11 11
 
12 12
 $xajax = new xajax();
13
-$xajax->registerFunction ('search_sessions');
13
+$xajax->registerFunction('search_sessions');
14 14
 
15 15
 // setting the section (for the tabs)
16 16
 $this_section = SECTION_PLATFORM_ADMIN;
@@ -19,13 +19,13 @@  discard block
 block discarded – undo
19 19
 api_protect_admin_script(true);
20 20
 
21 21
 // setting breadcrumbs
22
-$interbreadcrumb[]=array('url' => 'index.php','name' => get_lang('PlatformAdmin'));
23
-$interbreadcrumb[]=array('url' => 'career_dashboard.php','name' => get_lang('CareersAndPromotions'));
22
+$interbreadcrumb[] = array('url' => 'index.php', 'name' => get_lang('PlatformAdmin'));
23
+$interbreadcrumb[] = array('url' => 'career_dashboard.php', 'name' => get_lang('CareersAndPromotions'));
24 24
 
25 25
 // Setting the name of the tool
26 26
 $tool_name = get_lang('SubscribeSessionsToPromotions');
27 27
 $add_type = 'multiple';
28
-if (isset($_REQUEST['add_type']) && $_REQUEST['add_type']!=''){
28
+if (isset($_REQUEST['add_type']) && $_REQUEST['add_type'] != '') {
29 29
     $add_type = Security::remove_XSS($_REQUEST['add_type']);
30 30
 }
31 31
 
@@ -74,7 +74,7 @@  discard block
 block discarded – undo
74 74
     $form_sent = $_POST['form_sent'];
75 75
     $session_in_promotion_posted = $_POST['session_in_promotion_name'];
76 76
     if (!is_array($session_in_promotion_posted)) {
77
-        $session_in_promotion_posted=array($session_in_promotion_posted);
77
+        $session_in_promotion_posted = array($session_in_promotion_posted);
78 78
     }
79 79
     if ($form_sent == 1) {
80 80
         // Added a parameter to send emails when registering a user
@@ -119,15 +119,15 @@  discard block
 block discarded – undo
119 119
 }
120 120
 
121 121
 echo '<div class="actions">';
122
-echo '<a href="promotions.php">'.Display::return_icon('back.png',get_lang('Back'),'',ICON_SIZE_MEDIUM).'</a>';
122
+echo '<a href="promotions.php">'.Display::return_icon('back.png', get_lang('Back'), '', ICON_SIZE_MEDIUM).'</a>';
123 123
 echo '</div>';
124 124
 ?>
125 125
 
126
-<form name="formulaire" method="post" action="<?php echo api_get_self(); ?>?id=<?php echo $id; if(!empty($_GET['add'])) echo '&add=true' ; ?>" style="margin:0px;" <?php if($ajax_search){echo ' onsubmit="valide();"';}?>>
126
+<form name="formulaire" method="post" action="<?php echo api_get_self(); ?>?id=<?php echo $id; if (!empty($_GET['add'])) echo '&add=true'; ?>" style="margin:0px;" <?php if ($ajax_search) {echo ' onsubmit="valide();"'; }?>>
127 127
 <?php echo '<legend>'.$tool_name.' '.$promotion_data['name'].'</legend>';
128 128
 
129 129
 
130
-if ($add_type=='multiple') {
130
+if ($add_type == 'multiple') {
131 131
     $extraField = new \ExtraField('session');
132 132
     $extra_field_list = $extraField->get_all_extra_field_by_type(ExtraField::FIELD_TYPE_SELECT);
133 133
     $new_field_list = array();
@@ -139,7 +139,7 @@  discard block
 block discarded – undo
139 139
             echo '&nbsp;<select name="'.$varname.'">';
140 140
             echo '<option value="0">--'.get_lang('Select').'--</option>';
141 141
             foreach ($new_field['data'] as $option) {
142
-                $checked='';
142
+                $checked = '';
143 143
                 if (isset($_POST[$varname])) {
144 144
                     if ($_POST[$varname] == $option[1]) {
145 145
                         $checked = 'selected="true"';
@@ -170,7 +170,7 @@  discard block
 block discarded – undo
170 170
   <td align="center"><b><?php echo get_lang('SessionsInPromotion') ?> :</b></td>
171 171
 </tr>
172 172
 
173
-<?php if ($add_type=='multiple') { ?>
173
+<?php if ($add_type == 'multiple') { ?>
174 174
 <tr>
175 175
 <td align="center">
176 176
 <?php echo get_lang('FirstLetterSessions'); ?> :
@@ -188,7 +188,7 @@  discard block
 block discarded – undo
188 188
   <td align="center">
189 189
   <div id="content_source">
190 190
       <?php
191
-      if (!($add_type=='multiple')) {
191
+      if (!($add_type == 'multiple')) {
192 192
         ?>
193 193
         <input type="text" id="user_to_add" onkeyup="xajax_search_users(this.value,'single')" />
194 194
         <div id="ajax_list_users_single"></div>
@@ -196,7 +196,7 @@  discard block
 block discarded – undo
196 196
       } else {
197 197
       ?>
198 198
       <div id="ajax_list_multiple">
199
-        <?php echo Display::select('session_not_in_promotion_name',$session_not_in_promotion, '',array('style'=>'width:360px', 'multiple'=>'multiple','id'=>'session_not_in_promotion','size'=>'15px'),false); ?>
199
+        <?php echo Display::select('session_not_in_promotion_name', $session_not_in_promotion, '', array('style'=>'width:360px', 'multiple'=>'multiple', 'id'=>'session_not_in_promotion', 'size'=>'15px'), false); ?>
200 200
       </div>
201 201
     <?php
202 202
       }
@@ -231,7 +231,7 @@  discard block
 block discarded – undo
231 231
         'session_in_promotion_name[]',
232 232
         $session_in_promotion,
233 233
         '',
234
-        array('style'=>'width:360px', 'multiple'=>'multiple','id'=>'session_in_promotion','size'=>'15px'),
234
+        array('style'=>'width:360px', 'multiple'=>'multiple', 'id'=>'session_in_promotion', 'size'=>'15px'),
235 235
         false
236 236
     );
237 237
     unset($sessionUsersList);
@@ -341,7 +341,7 @@  discard block
 block discarded – undo
341 341
             }
342 342
         }
343 343
         $return .= '</select>';
344
-        $xajax_response -> addAssign('ajax_list_multiple','innerHTML',api_utf8_encode($return));
344
+        $xajax_response -> addAssign('ajax_list_multiple', 'innerHTML', api_utf8_encode($return));
345 345
     }
346 346
 
347 347
     return $xajax_response;
Please login to merge, or discard this patch.
main/admin/promotions.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -112,7 +112,7 @@
 block discarded – undo
112 112
 <script>
113 113
 $(function() {
114 114
 <?php
115
-     echo Display::grid_js('promotions', $url, $columns, $column_model, $extra_params, array(), $action_links, true);
115
+        echo Display::grid_js('promotions', $url, $columns, $column_model, $extra_params, array(), $action_links, true);
116 116
 ?>
117 117
 });
118 118
 </script>
Please login to merge, or discard this patch.
main/inc/ajax/exercise.ajax.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -488,7 +488,7 @@
 block discarded – undo
488 488
                     $remind_list
489 489
                 );
490 490
 
491
-                 // Destruction of the Question object
491
+                    // Destruction of the Question object
492 492
                 unset($objQuestionTmp);
493 493
                 if ($debug) {
494 494
                     error_log(" -- end question -- ");
Please login to merge, or discard this patch.
main/inc/ajax/model.ajax.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -731,7 +731,7 @@  discard block
 block discarded – undo
731 731
         }
732 732
 
733 733
         break;
734
-	case 'get_user_skill_ranking':
734
+    case 'get_user_skill_ranking':
735 735
         $columns = array('photo', 'firstname', 'lastname', 'skills_acquired', 'currently_learning', 'rank');
736 736
         $result = $skill->get_user_list_skill_ranking($start, $limit, $sidx, $sord, $whereCondition);
737 737
         $result = msort($result, 'skills_acquired', 'asc');
@@ -1281,7 +1281,7 @@  discard block
 block discarded – undo
1281 1281
 
1282 1282
             if (!empty($item['certif_min_score']) && !empty($item['document_id'])) {
1283 1283
                 $item['certificates'] = Display::return_icon('accept.png', get_lang('WithCertificate'), array(), ICON_SIZE_SMALL);
1284
-                 $item['has_certificates'] = '1';
1284
+                    $item['has_certificates'] = '1';
1285 1285
             } else {
1286 1286
                 $item['certificates'] = Display::return_icon('warning.png', get_lang('NoCertificate'), array(), ICON_SIZE_SMALL);
1287 1287
                 $item['has_certificates'] = '0';
Please login to merge, or discard this patch.
Spacing   +40 added lines, -40 removed lines patch added patch discarded remove patch
@@ -11,8 +11,8 @@  discard block
 block discarded – undo
11 11
 $action = $_GET['a'];
12 12
 $page = intval($_REQUEST['page']); //page
13 13
 $limit = intval($_REQUEST['rows']); //quantity of rows
14
-$sidx = $_REQUEST['sidx'];         //index (field) to filter
15
-$sord = $_REQUEST['sord'];         //asc or desc
14
+$sidx = $_REQUEST['sidx']; //index (field) to filter
15
+$sord = $_REQUEST['sord']; //asc or desc
16 16
 
17 17
 if (strpos(strtolower($sidx), 'asc') !== false) {
18 18
     $sidx = str_replace(array('asc', ','), '', $sidx);
@@ -24,7 +24,7 @@  discard block
 block discarded – undo
24 24
     $sord = 'desc';
25 25
 }
26 26
 
27
-if (!in_array($sord, array('asc','desc'))) {
27
+if (!in_array($sord, array('asc', 'desc'))) {
28 28
     $sord = 'desc';
29 29
 }
30 30
 
@@ -64,19 +64,19 @@  discard block
 block discarded – undo
64 64
 function getWhereClause($col, $oper, $val)
65 65
 {
66 66
     $ops = array(
67
-        'eq' => '=',        //equal
68
-        'ne' => '<>',       //not equal
69
-        'lt' => '<',        //less than
70
-        'le' => '<=',       //less than or equal
71
-        'gt' => '>',        //greater than
72
-        'ge' => '>=',       //greater than or equal
73
-        'bw' => 'LIKE',     //begins with
67
+        'eq' => '=', //equal
68
+        'ne' => '<>', //not equal
69
+        'lt' => '<', //less than
70
+        'le' => '<=', //less than or equal
71
+        'gt' => '>', //greater than
72
+        'ge' => '>=', //greater than or equal
73
+        'bw' => 'LIKE', //begins with
74 74
         'bn' => 'NOT LIKE', //doesn't begin with
75
-        'in' => 'LIKE',     //is in
75
+        'in' => 'LIKE', //is in
76 76
         'ni' => 'NOT LIKE', //is not in
77
-        'ew' => 'LIKE',     //ends with
77
+        'ew' => 'LIKE', //ends with
78 78
         'en' => 'NOT LIKE', //doesn't end with
79
-        'cn' => 'LIKE',     //contains
79
+        'cn' => 'LIKE', //contains
80 80
         'nc' => 'NOT LIKE'  //doesn't contain
81 81
     );
82 82
 
@@ -100,10 +100,10 @@  discard block
 block discarded – undo
100 100
 
101 101
 // If there is no search request sent by jqgrid, $where should be empty
102 102
 $whereCondition = '';
103
-$operation = isset($_REQUEST['oper'])  ? $_REQUEST['oper']  : false;
104
-$exportFormat = isset($_REQUEST['export_format'])  ? $_REQUEST['export_format']  : 'csv';
105
-$searchField = isset($_REQUEST['searchField'])  ? $_REQUEST['searchField']  : false;
106
-$searchOperator = isset($_REQUEST['searchOper'])   ? $_REQUEST['searchOper']   : false;
103
+$operation = isset($_REQUEST['oper']) ? $_REQUEST['oper'] : false;
104
+$exportFormat = isset($_REQUEST['export_format']) ? $_REQUEST['export_format'] : 'csv';
105
+$searchField = isset($_REQUEST['searchField']) ? $_REQUEST['searchField'] : false;
106
+$searchOperator = isset($_REQUEST['searchOper']) ? $_REQUEST['searchOper'] : false;
107 107
 $searchString = isset($_REQUEST['searchString']) ? $_REQUEST['searchString'] : false;
108 108
 $search = isset($_REQUEST['_search']) ? $_REQUEST['_search'] : false;
109 109
 $forceSearch = isset($_REQUEST['_force_search']) ? $_REQUEST['_force_search'] : false;
@@ -171,7 +171,7 @@  discard block
 block discarded – undo
171 171
             foreach ($filters->rules as $key => $rule) {
172 172
                 $whereCondition .= getWhereClause($rule->field, $rule->op, $rule->data);
173 173
 
174
-                if ($counter < count($filters->rules) -1) {
174
+                if ($counter < count($filters->rules) - 1) {
175 175
                     $whereCondition .= $filters->groupOp;
176 176
                 }
177 177
                 $counter++;
@@ -202,7 +202,7 @@  discard block
 block discarded – undo
202 202
         $userId = api_get_user_id();
203 203
         $sessionId = isset($_GET['session_id']) ? intval($_GET['session_id']) : 0;
204 204
         $courseCodeList = array();
205
-        $userIdList  = array();
205
+        $userIdList = array();
206 206
         $sessionIdList = [];
207 207
         $searchByGroups = false;
208 208
         if (api_is_drh()) {
@@ -650,7 +650,7 @@  discard block
 block discarded – undo
650 650
 $total_pages = 0;
651 651
 if ($count > 0) {
652 652
     if (!empty($limit)) {
653
-        $total_pages = ceil((float)$count/(float)$limit);
653
+        $total_pages = ceil((float) $count / (float) $limit);
654 654
     }
655 655
 }
656 656
 if ($page > $total_pages) {
@@ -809,7 +809,7 @@  discard block
 block discarded – undo
809 809
     
810 810
         //get sessions
811 811
         $arrSessions = array();
812
-        if(count($sessionIdList) > 0) {
812
+        if (count($sessionIdList) > 0) {
813 813
             $arrSessions = CourseManager::get_user_list_from_course_code(
814 814
                 null,
815 815
                 null,
@@ -955,10 +955,10 @@  discard block
 block discarded – undo
955 955
     case 'get_work_user_list_others':
956 956
         if (isset($_GET['type']) && $_GET['type'] === 'simple') {
957 957
             $columns = array(
958
-                'type', 'firstname', 'lastname',  'title', 'qualification', 'sent_date', 'qualificator_id', 'actions'
958
+                'type', 'firstname', 'lastname', 'title', 'qualification', 'sent_date', 'qualificator_id', 'actions'
959 959
             );
960 960
         } else {
961
-            $columns = array('type', 'firstname', 'lastname',  'title', 'sent_date', 'actions');
961
+            $columns = array('type', 'firstname', 'lastname', 'title', 'sent_date', 'actions');
962 962
         }
963 963
         $whereCondition .= " AND u.user_id <> ".api_get_user_id();
964 964
         $result = get_work_user_list($start, $limit, $sidx, $sord, $work_id, $whereCondition);
@@ -992,7 +992,7 @@  discard block
 block discarded – undo
992 992
     case 'get_exercise_results':
993 993
         $course = api_get_course_info();
994 994
         // Used inside ExerciseLib::get_exam_results_data()
995
-        $documentPath = api_get_path(SYS_COURSE_PATH) . $course['path'] . "/document";
995
+        $documentPath = api_get_path(SYS_COURSE_PATH).$course['path']."/document";
996 996
         if ($is_allowedToEdit || api_is_student_boss()) {
997 997
             $columns = array(
998 998
                 'firstname',
@@ -1024,11 +1024,11 @@  discard block
 block discarded – undo
1024 1024
         break;
1025 1025
     case 'get_hotpotatoes_exercise_results':
1026 1026
         $course = api_get_course_info();
1027
-        $documentPath = api_get_path(SYS_COURSE_PATH) . $course['path'] . "/document";
1027
+        $documentPath = api_get_path(SYS_COURSE_PATH).$course['path']."/document";
1028 1028
         if (api_is_allowed_to_edit()) {
1029
-            $columns = array('firstname', 'lastname', 'username', 'group_name', 'exe_date',  'score', 'actions');
1029
+            $columns = array('firstname', 'lastname', 'username', 'group_name', 'exe_date', 'score', 'actions');
1030 1030
         } else {
1031
-            $columns = array('exe_date',  'score', 'actions');
1031
+            $columns = array('exe_date', 'score', 'actions');
1032 1032
         }
1033 1033
         $result = ExerciseLib::get_exam_results_hotpotatoes_data(
1034 1034
             $start,
@@ -1061,12 +1061,12 @@  discard block
 block discarded – undo
1061 1061
         break;
1062 1062
     case 'get_hotpotatoes_exercise_results':
1063 1063
         $course = api_get_course_info();
1064
-        $documentPath = api_get_path(SYS_COURSE_PATH) . $course['path'] . "/document";
1064
+        $documentPath = api_get_path(SYS_COURSE_PATH).$course['path']."/document";
1065 1065
 
1066 1066
         if (api_is_allowed_to_edit(null, true) || api_is_drh()) {
1067
-            $columns = array('firstname', 'lastname', 'username', 'group_name', 'exe_date',  'score', 'actions');
1067
+            $columns = array('firstname', 'lastname', 'username', 'group_name', 'exe_date', 'score', 'actions');
1068 1068
         } else {
1069
-            $columns = array('exe_date',  'score', 'actions');
1069
+            $columns = array('exe_date', 'score', 'actions');
1070 1070
         }
1071 1071
         $result = ExerciseLib::get_exam_results_hotpotatoes_data(
1072 1072
             $start,
@@ -1138,17 +1138,17 @@  discard block
 block discarded – undo
1138 1138
                 $detailButtons = [];
1139 1139
                 $detailButtons[] = Display::url(
1140 1140
                     Display::return_icon('works.png', get_lang('WorksReport')),
1141
-                    api_get_path(WEB_CODE_PATH) . 'mySpace/works_in_session_report.php?session=' . $session['id']
1141
+                    api_get_path(WEB_CODE_PATH).'mySpace/works_in_session_report.php?session='.$session['id']
1142 1142
                 );
1143 1143
                 $detailButtons[] = Display::url(
1144 1144
                     Display::return_icon('2rightarrow.png'),
1145
-                    api_get_path(WEB_CODE_PATH) . 'mySpace/course.php?session_id=' . $session['id']
1145
+                    api_get_path(WEB_CODE_PATH).'mySpace/course.php?session_id='.$session['id']
1146 1146
                 );
1147 1147
 
1148 1148
                 $result[] = array(
1149 1149
                     'name' => Display::url(
1150 1150
                         $session['name'],
1151
-                        api_get_path(WEB_CODE_PATH) . 'mySpace/course.php?session_id=' . $session['id']
1151
+                        api_get_path(WEB_CODE_PATH).'mySpace/course.php?session_id='.$session['id']
1152 1152
                     ),
1153 1153
                     'date' => $session_date_string,
1154 1154
                     'course_per_session' => $count_courses_in_session,
@@ -1460,7 +1460,7 @@  discard block
 block discarded – undo
1460 1460
         $result = $new_result;
1461 1461
         break;
1462 1462
     case 'get_gradebooks':
1463
-        $columns = array('name', 'certificates','skills', 'actions', 'has_certificates');
1463
+        $columns = array('name', 'certificates', 'skills', 'actions', 'has_certificates');
1464 1464
         if (!in_array($sidx, $columns)) {
1465 1465
             $sidx = 'name';
1466 1466
         }
@@ -1629,7 +1629,7 @@  discard block
 block discarded – undo
1629 1629
                     if (!empty($exercises[$cnt - 4]['title'])) {
1630 1630
                         $title = ucwords(strtolower(trim($exercises[$cnt - 4]['title'])));
1631 1631
                     }
1632
-                    $columns[] = 'exer' . $i;
1632
+                    $columns[] = 'exer'.$i;
1633 1633
                     $column_names[] = $title;
1634 1634
                     $i++;
1635 1635
                     break;
@@ -1662,7 +1662,7 @@  discard block
 block discarded – undo
1662 1662
             $sessionInfo = SessionManager::fetch($listUserSess[$user['user_id']]['id_session']);
1663 1663
             $result[$i]['session'] = $sessionInfo['name'];
1664 1664
             $result[$i]['username'] = $user['username'];
1665
-            $result[$i]['name'] = $user['lastname'] . " " . $user['firstname'];
1665
+            $result[$i]['name'] = $user['lastname']." ".$user['firstname'];
1666 1666
             $j = 1;
1667 1667
             $finalScore = 0;
1668 1668
             foreach ($quizIds as $quizID) {
@@ -1670,7 +1670,7 @@  discard block
 block discarded – undo
1670 1670
                 if (!empty($arrGrade [$user['user_id']][$quizID]) || $arrGrade [$user['user_id']][$quizID] == 0) {
1671 1671
                     $finalScore += $grade = $arrGrade [$user['user_id']][$quizID];
1672 1672
                 }
1673
-                $result[$i]['exer' . $j] = $grade;
1673
+                $result[$i]['exer'.$j] = $grade;
1674 1674
                 $j++;
1675 1675
             }
1676 1676
 
@@ -1838,9 +1838,9 @@  discard block
 block discarded – undo
1838 1838
         foreach ($result as $row) {
1839 1839
             // if results tab give not id, set id to $i otherwise id="null" for all <tr> of the jqgrid - ref #4235
1840 1840
             if (!isset($row['id']) || isset($row['id']) && $row['id'] == '') {
1841
-                $response->rows[$i]['id']= $i;
1841
+                $response->rows[$i]['id'] = $i;
1842 1842
             } else {
1843
-                $response->rows[$i]['id']= $row['id'];
1843
+                $response->rows[$i]['id'] = $row['id'];
1844 1844
             }
1845 1845
             $array = array();
1846 1846
             foreach ($columns as $col) {
@@ -1850,7 +1850,7 @@  discard block
 block discarded – undo
1850 1850
                     $array[] = isset($row[$col]) ? Security::remove_XSS($row[$col]) : '';
1851 1851
                 }
1852 1852
             }
1853
-            $response->rows[$i]['cell']=$array;
1853
+            $response->rows[$i]['cell'] = $array;
1854 1854
             $i++;
1855 1855
         }
1856 1856
     }
Please login to merge, or discard this patch.
main/inc/local.inc.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -758,7 +758,7 @@
 block discarded – undo
758 758
     //    $gidReset = true;
759 759
 } // end else
760 760
 
761
- // Now check for anonymous user mode
761
+    // Now check for anonymous user mode
762 762
 if (isset($use_anonymous) && $use_anonymous) {
763 763
     //if anonymous mode is set, then try to set the current user as anonymous
764 764
     //if he doesn't have a login yet
Please login to merge, or discard this patch.