Completed
Push — 1.11.x ( 4463da...cd5efc )
by José
55:32 queued 28:22
created
main/inc/lib/search/search_widget.php 1 patch
Indentation   +21 added lines, -21 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@  discard block
 block discarded – undo
30 30
  * Get one term html select
31 31
  */
32 32
 function format_one_specific_field_select($prefix, $sf_term_array, $op, $extra_select_attr='size="7" class="sf-select-multiple"') {
33
-	global $charset;
33
+    global $charset;
34 34
     $multiple_select = '<select '. $extra_select_attr .' title="'. $prefix .'" id="sf-'. $prefix .'" name="sf_'. $prefix .'[]">';
35 35
 
36 36
     $all_selected = '';
@@ -119,20 +119,20 @@  discard block
 block discarded – undo
119 119
      * could not send a form in pagination
120 120
      */
121 121
 
122
-	if (isset($_GET['action']) && strcmp(trim($_GET['action']),'search')===0) {
123
-		$action='index.php';
124
-	}
125
-	$navigator_info = api_get_navigator();
122
+    if (isset($_GET['action']) && strcmp(trim($_GET['action']),'search')===0) {
123
+        $action='index.php';
124
+    }
125
+    $navigator_info = api_get_navigator();
126 126
 
127
-	if ($navigator_info['name']=='Internet Explorer' &&  $navigator_info['version']=='6') {
128
-		$submit_button1	= '<input type="submit" id="submit" value="'. get_lang('Search') .'" />';
129
-		$submit_button2 = '<input class="lower-submit" type="submit" value="'. get_lang('Search') .'" />';
127
+    if ($navigator_info['name']=='Internet Explorer' &&  $navigator_info['version']=='6') {
128
+        $submit_button1	= '<input type="submit" id="submit" value="'. get_lang('Search') .'" />';
129
+        $submit_button2 = '<input class="lower-submit" type="submit" value="'. get_lang('Search') .'" />';
130 130
         $reset_button 	= '<input type="submit" id="tags-clean" value="'. get_lang('SearchResetKeywords') .'" />';
131
-	} else {
132
-		$submit_button1 = '<button class="search" type="submit" id="submit" value="'. get_lang("Search") .'" /> '. get_lang('Search') .'</button>';
133
-		$submit_button2 = '<button class="search" type="submit" value="'. get_lang('Search') .'" />'. get_lang('Search') .'</button>';
131
+    } else {
132
+        $submit_button1 = '<button class="search" type="submit" id="submit" value="'. get_lang("Search") .'" /> '. get_lang('Search') .'</button>';
133
+        $submit_button2 = '<button class="search" type="submit" value="'. get_lang('Search') .'" />'. get_lang('Search') .'</button>';
134 134
         $reset_button 	= '<button class="save"   type="submit" id="tags-clean" value="'. get_lang('SearchResetKeywords') .'" />'. get_lang('SearchResetKeywords') .'</button> ';
135
-	}
135
+    }
136 136
 
137 137
     $query = isset($_REQUEST['query']) ? Security::remove_XSS($_REQUEST['query']) : null;
138 138
 
@@ -199,9 +199,9 @@  discard block
 block discarded – undo
199 199
      * SortableTableFromArray pagination is done with simple links, so now we
200 200
      * could not send a form in pagination
201 201
      */
202
-	if (isset($_GET['action']) && strcmp(trim($_GET['action']),'search')===0) {
203
-		$action='index.php';
204
-	}
202
+    if (isset($_GET['action']) && strcmp(trim($_GET['action']),'search')===0) {
203
+        $action='index.php';
204
+    }
205 205
 
206 206
     $form = '
207 207
         <form id="chamilo_search" action="'. $action .'" method="GET">
@@ -266,7 +266,7 @@  discard block
 block discarded – undo
266 266
                         </table>
267 267
                     </div>';
268 268
         }
269
-       $form .= '
269
+        $form .= '
270 270
         </form>
271 271
         <br style="clear: both;"/>';
272 272
 
@@ -324,10 +324,10 @@  discard block
 block discarded – undo
324 324
         foreach ($specific_fields as $specific_field) {
325 325
             $temp = array();
326 326
             if (is_array($dkterms) && count($dkterms)>0) {
327
-            	foreach($dkterms[1] as $obj) {
328
-                	$temp = array_merge($obj['sf-'.$specific_field['code']], $temp);
329
-            	}
330
-        	}
327
+                foreach($dkterms[1] as $obj) {
328
+                    $temp = array_merge($obj['sf-'.$specific_field['code']], $temp);
329
+                }
330
+            }
331 331
             $sf_terms[$specific_field['code']] = $temp;
332 332
             $url_params[] = 'sf_'.$specific_field['code'];
333 333
             unset($temp);
@@ -342,7 +342,7 @@  discard block
 block discarded – undo
342 342
     }
343 343
     echo '<h2>'.get_lang('Search').'</h2>';
344 344
 
345
-	// Tool introduction
345
+    // Tool introduction
346 346
     // TODO: Settings for the online editor to be checked (insert an image for example). Probably this is a special case here.
347 347
     if (api_get_course_id() !== -1)
348 348
     if (!empty($groupId)) {
Please login to merge, or discard this patch.
main/inc/lib/security.lib.php 1 patch
Indentation   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -261,9 +261,9 @@  discard block
 block discarded – undo
261 261
      */
262 262
     public static function remove_XSS($var, $user_status = null, $filter_terms = false)
263 263
     {
264
-    	if ($filter_terms) {
265
-    		$var = self::filter_terms($var);
266
-    	}
264
+        if ($filter_terms) {
265
+            $var = self::filter_terms($var);
266
+        }
267 267
 
268 268
         if (empty($user_status)) {
269 269
             if (api_is_anonymous()) {
@@ -358,7 +358,7 @@  discard block
 block discarded – undo
358 358
      */
359 359
     public static function filter_terms($text)
360 360
     {
361
-    	static $bad_terms = array();
361
+        static $bad_terms = array();
362 362
 
363 363
         if (empty($bad_terms)) {
364 364
             $list = api_get_setting('filter_terms');
@@ -379,14 +379,14 @@  discard block
 block discarded – undo
379 379
             }
380 380
         }
381 381
 
382
-    	$replace = '***';
383
-    	if (!empty($bad_terms)) {
384
-    		// Fast way
385
-    		$new_text = str_ireplace($bad_terms, $replace, $text, $count);
386
-    		$text = $new_text;
387
-    	}
382
+        $replace = '***';
383
+        if (!empty($bad_terms)) {
384
+            // Fast way
385
+            $new_text = str_ireplace($bad_terms, $replace, $text, $count);
386
+            $text = $new_text;
387
+        }
388 388
 
389
-		return $text;
389
+        return $text;
390 390
     }
391 391
 
392 392
     /**
Please login to merge, or discard this patch.
main/auth/profile.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -628,7 +628,7 @@
 block discarded – undo
628 628
 
629 629
     foreach ($user_data as $key => $value) {
630 630
         if (substr($key, 0, 6) === 'extra_') { //an extra field
631
-           continue;
631
+            continue;
632 632
         } elseif (strpos($key, 'remove_extra_') !== false) {
633 633
         } else {
634 634
             if (in_array($key, $available_values_to_modify)) {
Please login to merge, or discard this patch.
main/course_home/course_home.php 1 patch
Indentation   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -203,7 +203,7 @@  discard block
 block discarded – undo
203 203
             if (Database::num_rows($result) ==  0) {
204 204
                 $condition = '';
205 205
             } else {
206
-            	//great, there is an specific auto launch for this session we leave the $condition
206
+                //great, there is an specific auto launch for this session we leave the $condition
207 207
             }
208 208
         }
209 209
 
@@ -215,7 +215,7 @@  discard block
 block discarded – undo
215 215
             $lp_data = Database::fetch_array($result,'ASSOC');
216 216
             if (!empty($lp_data['id'])) {
217 217
                 if (api_is_platform_admin() || api_is_allowed_to_edit()) {
218
-                	$show_autolaunch_lp_warning = true;
218
+                    $show_autolaunch_lp_warning = true;
219 219
                 } else {
220 220
                     $session_key = 'lp_autolaunch_'.$session_id.'_'.api_get_course_int_id().'_'.api_get_user_id();
221 221
                     if (!isset($_SESSION[$session_key])) {
@@ -244,7 +244,7 @@  discard block
 block discarded – undo
244 244
         //if (!isset($_SESSION[$forumKey])) {
245 245
             //redirecting to the LP
246 246
             $url = api_get_path(WEB_CODE_PATH).'forum/index.php?'.api_get_cidreq().'&id_session='.$session_id;
247
-          //  $_SESSION[$forumKey] = true;
247
+            //  $_SESSION[$forumKey] = true;
248 248
             header("Location: $url");
249 249
             exit;
250 250
         //}
@@ -280,13 +280,13 @@  discard block
 block discarded – undo
280 280
 }
281 281
 
282 282
 if (api_get_setting('homepage_view') === 'activity' || api_get_setting('homepage_view') === 'activity_big') {
283
-	require 'activity.php';
283
+    require 'activity.php';
284 284
 } elseif (api_get_setting('homepage_view') === '2column') {
285
-	require '2column.php';
285
+    require '2column.php';
286 286
 } elseif (api_get_setting('homepage_view') === '3column') {
287
-	require '3column.php';
287
+    require '3column.php';
288 288
 } elseif (api_get_setting('homepage_view') === 'vertical_activity') {
289
-	require 'vertical_activity.php';
289
+    require 'vertical_activity.php';
290 290
 }
291 291
 
292 292
 $content = '<div id="course_tools">'.$content.'</div>';
Please login to merge, or discard this patch.
main/install/update-configuration.inc.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -38,7 +38,7 @@
 block discarded – undo
38 38
         if (stripos($line, '$_configuration[\'system_version\']') !== false) {
39 39
             $found_version = true;
40 40
             $line = '$_configuration[\'system_version\'] = \'' . $GLOBALS['new_version'] . '\';' . "\r\n";
41
-       } elseif (stripos($line, '$_configuration[\'system_stable\']') !== false) {
41
+        } elseif (stripos($line, '$_configuration[\'system_stable\']') !== false) {
42 42
             $found_stable = true;
43 43
             $line = '$_configuration[\'system_stable\'] = ' . ($GLOBALS['new_version_stable'] ? 'true' : 'false') . ';' . "\r\n";
44 44
         } elseif (stripos($line, '$_configuration[\'software_name\']') !== false) {
Please login to merge, or discard this patch.
main/install/install.lib.php 1 patch
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -1745,7 +1745,7 @@  discard block
 block discarded – undo
1745 1745
         $html .= '<label class="checkbox-inline">
1746 1746
                         <input type="radio" name="allowSelfReg" value="false" id="allowSelfReg0" '. ($allowSelfReg == 'false' ? '' : 'checked="checked" ') .' /> '. get_lang('No') .'
1747 1747
                     </label>';
1748
-         $html .= '<label class="checkbox-inline">
1748
+            $html .= '<label class="checkbox-inline">
1749 1749
                     <input type="radio" name="allowSelfReg" value="approval" id="allowSelfReg2" '. ($allowSelfReg == 'approval' ? '' : 'checked="checked" ') .' /> '. get_lang('AfterApproval') .'
1750 1750
                 </label>';
1751 1751
         $html .= '</div>';
@@ -1779,7 +1779,7 @@  discard block
 block discarded – undo
1779 1779
     </div>';
1780 1780
 
1781 1781
     echo panel($html, get_lang('Platform'), 'platform');
1782
- ?>
1782
+    ?>
1783 1783
     <div class='form-group'>
1784 1784
         <div class="col-sm-6">
1785 1785
             <button type="submit" class="btn btn-default pull-right" name="step3" value="&lt; <?php echo get_lang('Previous'); ?>" ><em class="fa fa-backward"> </em> <?php echo get_lang('Previous'); ?></button>
Please login to merge, or discard this patch.
main/social/profile.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -596,7 +596,7 @@
 block discarded – undo
596 596
                                 .' width="40px">';
597 597
                     $userInfo = api_get_user_info($user_invitation_id);
598 598
                     $invitations .= '<a href="'.api_get_path(WEB_PATH).'main/social/profile.php?u='.$user_invitation_id.'">'
599
-                                 .api_get_person_name($userInfo['firstname'],$userInfo['lastname']).'</a>';
599
+                                    .api_get_person_name($userInfo['firstname'],$userInfo['lastname']).'</a>';
600 600
 
601 601
                     $invitations .='<div class="pull-right">';
602 602
                     $invitations .= Display::toolbarButton(
Please login to merge, or discard this patch.
main/upload/index.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@
 block discarded – undo
37 37
 
38 38
 $is_allowed_to_edit = api_is_allowed_to_edit(null, true);
39 39
 if (!$is_allowed_to_edit) {
40
-	api_not_allowed(true);
40
+    api_not_allowed(true);
41 41
 }
42 42
 
43 43
 $courseDir = $_course['path'] . "/document";
Please login to merge, or discard this patch.
main/exercise/question_list_admin.inc.php 1 patch
Indentation   -1 removed lines patch added patch discarded remove patch
@@ -5,7 +5,6 @@
 block discarded – undo
5 5
  *	Code library for HotPotatoes integration.
6 6
  *	@package chamilo.exercise
7 7
  *	@author Olivier Brouckaert & Julio Montoya & Hubert Borderiou 21-10-2011 (Question by category)
8
-
9 8
  *	QUESTION LIST ADMINISTRATION
10 9
  *
11 10
  *	This script allows to manage the question list
Please login to merge, or discard this patch.