Completed
Push — 1.11.x ( 683301...61da54 )
by José
78:34 queued 46:29
created
main/mySpace/user_edit.php 2 patches
Indentation   +35 added lines, -35 removed lines patch added patch discarded remove patch
@@ -113,23 +113,23 @@  discard block
 block discarded – undo
113 113
 $form->addGroup($html_results_enabled);
114 114
 // Validate form
115 115
 if ($form->validate()) {
116
-	$check = Security::check_token('post');
117
-	if ($check) {
118
-		$user = $form->exportValues();
119
-		$email = $userInfo['email'];
116
+    $check = Security::check_token('post');
117
+    if ($check) {
118
+        $user = $form->exportValues();
119
+        $email = $userInfo['email'];
120 120
         $username = $userInfo['username'];
121
-		$send_mail = intval($user['mail']['send_mail']);
121
+        $send_mail = intval($user['mail']['send_mail']);
122 122
         $auth_source = PLATFORM_AUTH_SOURCE;
123 123
 
124 124
         $resetPassword = $user['password']['password_auto'] == '1' ? 0 : 2;
125 125
 
126
-		if (count($extAuthSource) > 0 && $user['password']['password_auto'] == '2') {
127
-			//$auth_source = $user['password']['auth_source'];
128
-			//$password = 'PLACEHOLDER';
129
-		} else {
130
-			//$auth_source = PLATFORM_AUTH_SOURCE;
131
-			//$password = $user['password']['password_auto'] == '1' ? api_generate_password() : $user['password']['password'];
132
-		}
126
+        if (count($extAuthSource) > 0 && $user['password']['password_auto'] == '2') {
127
+            //$auth_source = $user['password']['auth_source'];
128
+            //$password = 'PLACEHOLDER';
129
+        } else {
130
+            //$auth_source = PLATFORM_AUTH_SOURCE;
131
+            //$password = $user['password']['password_auto'] == '1' ? api_generate_password() : $user['password']['password'];
132
+        }
133 133
 
134 134
         $auth_source = $userInfo['auth_source'];
135 135
         $password = $user['password']['password_auto'] == '1' ? api_generate_password() : $user['password']['password'];
@@ -157,18 +157,18 @@  discard block
 block discarded – undo
157 157
             $resetPassword
158 158
         );
159 159
 
160
-		if (!empty($email) && $send_mail) {
161
-			$emailsubject = '['.api_get_setting('siteName').'] '.get_lang('YourReg').' '.api_get_setting('siteName');
162
-			$portal_url = api_get_path(WEB_PATH);
163
-			if (api_is_multiple_url_enabled()) {
164
-				$access_url_id = api_get_current_access_url_id();
165
-				if ($access_url_id != -1) {
166
-					$url = api_get_access_url($access_url_id);
167
-					$portal_url = $url['url'];
168
-				}
169
-			}
170
-
171
-			$emailbody = get_lang('Dear')." ".stripslashes(api_get_person_name($userInfo['firstname'], $userInfo['lastname'])).",\n\n".
160
+        if (!empty($email) && $send_mail) {
161
+            $emailsubject = '['.api_get_setting('siteName').'] '.get_lang('YourReg').' '.api_get_setting('siteName');
162
+            $portal_url = api_get_path(WEB_PATH);
163
+            if (api_is_multiple_url_enabled()) {
164
+                $access_url_id = api_get_current_access_url_id();
165
+                if ($access_url_id != -1) {
166
+                    $url = api_get_access_url($access_url_id);
167
+                    $portal_url = $url['url'];
168
+                }
169
+            }
170
+
171
+            $emailbody = get_lang('Dear')." ".stripslashes(api_get_person_name($userInfo['firstname'], $userInfo['lastname'])).",\n\n".
172 172
                 get_lang('YouAreReg')." ". api_get_setting('siteName') ." ".get_lang('WithTheFollowingSettings')."\n\n".
173 173
                 get_lang('Username')." : ". $username ."\n". get_lang('Pass')." : ".stripslashes($password)."\n\n" .
174 174
                 get_lang('Address') ." ". api_get_setting('siteName') ." ".
@@ -181,26 +181,26 @@  discard block
 block discarded – undo
181 181
                 api_get_setting('administratorTelephone')."\n" .
182 182
                 get_lang('Email') ." : ".api_get_setting('emailAdministrator');
183 183
 
184
-			api_mail_html(
184
+            api_mail_html(
185 185
                 api_get_person_name($userInfo['firstname'], $userInfo['lastname'], null, PERSON_NAME_EMAIL_ADDRESS),
186 186
                 $email,
187 187
                 $emailsubject,
188 188
                 $emailbody
189 189
             );
190
-		}
190
+        }
191 191
 
192
-		Security::clear_token();
192
+        Security::clear_token();
193 193
         $tok = Security::get_token();
194 194
         header('Location: '.$url.'&message=1');
195 195
         exit();
196
-	}
196
+    }
197 197
 } else {
198
-	if (isset($_POST['submit'])) {
199
-		Security::clear_token();
200
-	}
201
-	$token = Security::get_token();
202
-	$form->addElement('hidden', 'sec_token');
203
-	$form->setConstants(array('sec_token' => $token));
198
+    if (isset($_POST['submit'])) {
199
+        Security::clear_token();
200
+    }
201
+    $token = Security::get_token();
202
+    $form->addElement('hidden', 'sec_token');
203
+    $form->setConstants(array('sec_token' => $token));
204 204
 }
205 205
 
206 206
 $interbreadcrumb[] = array(
@@ -212,7 +212,7 @@  discard block
 block discarded – undo
212 212
 Display::display_header($tool_name);
213 213
 
214 214
 if (isset($_REQUEST['message'])) {
215
-	Display::display_normal_message(get_lang('Updated'));
215
+    Display::display_normal_message(get_lang('Updated'));
216 216
 }
217 217
 $form->display();
218 218
 
Please login to merge, or discard this patch.
Spacing   +14 added lines, -14 removed lines patch added patch discarded remove patch
@@ -89,15 +89,15 @@  discard block
 block discarded – undo
89 89
 	$group[] =& $form->createElement('select', 'auth_source', null, $auth_sources);
90 90
 	$group[] =& $form->createElement('static', '', '', '<br />');
91 91
 }*/
92
-$group[] =& $form->createElement('radio', 'password_auto', get_lang('Password'), get_lang('AutoGeneratePassword').'<br />', 1);
93
-$group[] =& $form->createElement('radio', 'password_auto', 'id="radio_user_password"', null, 0);
94
-$group[] =& $form->createElement('password', 'password', null, array('onkeydown' => 'javascript: password_switch_radio_button(document.user_add,"password[password_auto]");'));
92
+$group[] = & $form->createElement('radio', 'password_auto', get_lang('Password'), get_lang('AutoGeneratePassword').'<br />', 1);
93
+$group[] = & $form->createElement('radio', 'password_auto', 'id="radio_user_password"', null, 0);
94
+$group[] = & $form->createElement('password', 'password', null, array('onkeydown' => 'javascript: password_switch_radio_button(document.user_add,"password[password_auto]");'));
95 95
 $form->addGroup($group, 'password', get_lang('Password'), '');
96 96
 
97 97
 // Send email
98 98
 $group = array();
99
-$group[] =& $form->createElement('radio', 'send_mail', null, get_lang('Yes'), 1);
100
-$group[] =& $form->createElement('radio', 'send_mail', null, get_lang('No'), 0);
99
+$group[] = & $form->createElement('radio', 'send_mail', null, get_lang('Yes'), 1);
100
+$group[] = & $form->createElement('radio', 'send_mail', null, get_lang('No'), 0);
101 101
 $form->addGroup($group, 'mail', get_lang('SendMailToNewUser'), '&nbsp;');
102 102
 
103 103
 // Set default values
@@ -108,7 +108,7 @@  discard block
 block discarded – undo
108 108
 
109 109
 $form->setDefaults($defaults);
110 110
 // Submit button
111
-$select_level = array ();
111
+$select_level = array();
112 112
 $html_results_enabled[] = $form->addButtonUpdate(get_lang('Update'), 'submit', true);
113 113
 $form->addGroup($html_results_enabled);
114 114
 // Validate form
@@ -169,17 +169,17 @@  discard block
 block discarded – undo
169 169
 			}
170 170
 
171 171
 			$emailbody = get_lang('Dear')." ".stripslashes(api_get_person_name($userInfo['firstname'], $userInfo['lastname'])).",\n\n".
172
-                get_lang('YouAreReg')." ". api_get_setting('siteName') ." ".get_lang('WithTheFollowingSettings')."\n\n".
173
-                get_lang('Username')." : ". $username ."\n". get_lang('Pass')." : ".stripslashes($password)."\n\n" .
174
-                get_lang('Address') ." ". api_get_setting('siteName') ." ".
175
-                get_lang('Is') ." : ".$portal_url."\n\n".
176
-                get_lang('Problem'). "\n\n".
172
+                get_lang('YouAreReg')." ".api_get_setting('siteName')." ".get_lang('WithTheFollowingSettings')."\n\n".
173
+                get_lang('Username')." : ".$username."\n".get_lang('Pass')." : ".stripslashes($password)."\n\n".
174
+                get_lang('Address')." ".api_get_setting('siteName')." ".
175
+                get_lang('Is')." : ".$portal_url."\n\n".
176
+                get_lang('Problem')."\n\n".
177 177
                 get_lang('SignatureFormula').",\n\n".
178 178
                 api_get_person_name(api_get_setting('administratorName'), api_get_setting('administratorSurname'))."\n".
179
-                get_lang('Manager'). " ".
179
+                get_lang('Manager')." ".
180 180
                 api_get_setting('siteName')."\nT. ".
181
-                api_get_setting('administratorTelephone')."\n" .
182
-                get_lang('Email') ." : ".api_get_setting('emailAdministrator');
181
+                api_get_setting('administratorTelephone')."\n".
182
+                get_lang('Email')." : ".api_get_setting('emailAdministrator');
183 183
 
184 184
 			api_mail_html(
185 185
                 api_get_person_name($userInfo['firstname'], $userInfo['lastname'], null, PERSON_NAME_EMAIL_ADDRESS),
Please login to merge, or discard this patch.
main/mySpace/index.php 2 patches
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -102,7 +102,7 @@  discard block
 block discarded – undo
102 102
 }
103 103
 
104 104
 if ($is_drh) {
105
-	$view = 'drh';
105
+    $view = 'drh';
106 106
     $menu_items[] = Display::url(Display::return_icon('user_na.png', get_lang('Students'), array(), ICON_SIZE_MEDIUM), '#');
107 107
     $menu_items[] = Display::url(Display::return_icon('teacher.png', get_lang('Trainers'), array(), ICON_SIZE_MEDIUM), 'teachers.php');
108 108
     $menu_items[] = Display::url(Display::return_icon('course.png', get_lang('Courses'), array(), ICON_SIZE_MEDIUM), 'course.php');
@@ -143,7 +143,7 @@  discard block
 block discarded – undo
143 143
         echo "</div><br />";
144 144
     }
145 145
 } else {
146
-	echo Display::url(
146
+    echo Display::url(
147 147
         Display::return_icon('stats.png', get_lang('MyStats'),'',ICON_SIZE_MEDIUM),
148 148
         api_get_path(WEB_CODE_PATH)."auth/my_progress.php"
149 149
     );
@@ -397,11 +397,11 @@  discard block
 block discarded – undo
397 397
 
398 398
 // Send the csv file if asked
399 399
 if ($export_csv) {
400
-	ob_end_clean();
401
-	Export :: arrayToCsv($csv_content, 'reporting_index');
402
-	exit;
400
+    ob_end_clean();
401
+    Export :: arrayToCsv($csv_content, 'reporting_index');
402
+    exit;
403 403
 }
404 404
 
405 405
 if (!$export_csv) {
406
-	Display::display_footer();
406
+    Display::display_footer();
407 407
 }
Please login to merge, or discard this patch.
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -27,13 +27,13 @@  discard block
 block discarded – undo
27 27
 $session_id = isset($_GET['session_id']) ? intval($_GET['session_id']) : 0;
28 28
 
29 29
 $is_coach = api_is_coach($session_id);
30
-$is_platform_admin 	= api_is_platform_admin();
31
-$is_drh 			= api_is_drh();
32
-$is_session_admin 	= api_is_session_admin();
30
+$is_platform_admin = api_is_platform_admin();
31
+$is_drh = api_is_drh();
32
+$is_session_admin = api_is_session_admin();
33 33
 
34
-$count_sessions 	= 0;
35
-$count_courses		= 0;
36
-$title 				= null;
34
+$count_sessions = 0;
35
+$count_courses = 0;
36
+$title = null;
37 37
 
38 38
 // Access control
39 39
 api_block_anonymous_users();
@@ -124,7 +124,7 @@  discard block
 block discarded – undo
124 124
 echo '</span>';
125 125
 
126 126
 if (!empty($session_id) &&
127
-    !in_array($display, array('accessoverview','lpprogressoverview','progressoverview','exerciseprogress', 'surveyoverview'))
127
+    !in_array($display, array('accessoverview', 'lpprogressoverview', 'progressoverview', 'exerciseprogress', 'surveyoverview'))
128 128
 ) {
129 129
     echo '<a href="index.php">'.Display::return_icon('back.png', get_lang('Back'), '', ICON_SIZE_MEDIUM).'</a>';
130 130
     if (!api_is_platform_admin()) {
@@ -144,19 +144,19 @@  discard block
 block discarded – undo
144 144
     }
145 145
 } else {
146 146
 	echo Display::url(
147
-        Display::return_icon('stats.png', get_lang('MyStats'),'',ICON_SIZE_MEDIUM),
147
+        Display::return_icon('stats.png', get_lang('MyStats'), '', ICON_SIZE_MEDIUM),
148 148
         api_get_path(WEB_CODE_PATH)."auth/my_progress.php"
149 149
     );
150 150
     echo Display::url(
151 151
         Display::return_icon("certificate_list.png", get_lang("GradebookSeeListOfStudentsCertificates"), array(), ICON_SIZE_MEDIUM),
152
-        api_get_path(WEB_CODE_PATH) . "gradebook/certificate_report.php"
152
+        api_get_path(WEB_CODE_PATH)."gradebook/certificate_report.php"
153 153
     );
154 154
 }
155 155
 
156 156
 // Actions menu
157 157
 $nb_menu_items = count($menu_items);
158 158
 if (empty($session_id) ||
159
-    in_array($display, array('accessoverview','lpprogressoverview', 'progressoverview', 'exerciseprogress', 'surveyoverview'))
159
+    in_array($display, array('accessoverview', 'lpprogressoverview', 'progressoverview', 'exerciseprogress', 'surveyoverview'))
160 160
 ) {
161 161
     if ($nb_menu_items > 1) {
162 162
         foreach ($menu_items as $key => $item) {
@@ -167,7 +167,7 @@  discard block
 block discarded – undo
167 167
 
168 168
 echo '</div>';
169 169
 
170
-$userId  = api_get_user_id();
170
+$userId = api_get_user_id();
171 171
 $stats = Tracking::getStats($userId);
172 172
 
173 173
 $students = $stats['students'];
@@ -207,7 +207,7 @@  discard block
 block discarded – undo
207 207
 if (!empty($students)) {
208 208
     // Students
209 209
     $nb_students = count($students);
210
-    $progress  = Tracking::get_avg_student_progress($studentIds);
210
+    $progress = Tracking::get_avg_student_progress($studentIds);
211 211
     $countAssignments = Tracking::count_student_assignments($studentIds);
212 212
     $studentIds = array_values($students);
213 213
     $countHumanResourcesUsers = count($humanResourcesUsers);
Please login to merge, or discard this patch.
main/mySpace/progression.php 2 patches
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -16,14 +16,14 @@
 block discarded – undo
16 16
 $this_section = SECTION_TRACKING;
17 17
 
18 18
 api_block_anonymous_users();
19
-$interbreadcrumb[] = array ("url" => "index.php", "name" => get_lang('MySpace'));
19
+$interbreadcrumb[] = array("url" => "index.php", "name" => get_lang('MySpace'));
20 20
 Display :: display_header($nameTools);
21 21
 
22 22
 // Database Table Definitions
23
-$tbl_course 		= Database :: get_main_table(TABLE_MAIN_COURSE);
24
-$tbl_user 			= Database :: get_main_table(TABLE_MAIN_USER);
23
+$tbl_course = Database :: get_main_table(TABLE_MAIN_COURSE);
24
+$tbl_user = Database :: get_main_table(TABLE_MAIN_USER);
25 25
 $tbl_session_course = Database :: get_main_table(TABLE_MAIN_SESSION_COURSE);
26
-$tbl_session 		= Database :: get_main_table(TABLE_MAIN_SESSION);
26
+$tbl_session = Database :: get_main_table(TABLE_MAIN_SESSION);
27 27
 $tbl_track_exercice = Database :: get_main_table(TABLE_STATISTIC_TRACK_E_EXERCISES);
28 28
 
29 29
 /*
Please login to merge, or discard this patch.
Indentation   +27 added lines, -27 removed lines patch added patch discarded remove patch
@@ -33,36 +33,36 @@
 block discarded – undo
33 33
 $result_course = Database::query($sql_course);
34 34
 
35 35
 if (Database::num_rows($result_course) > 0) {
36
-	if (isset($_POST['export'])) {
37
-		$export_result = export_csv($header, $data, 'test.csv'); // TODO: There is no data for exporting yet.
38
-		Display :: display_error_message($export_result);
39
-	}
40
-	echo '<table class="data_table"><tr><th>'.get_lang('Course').'</th><th>'.get_lang('TempsFrequentation').'</th><th>'.get_lang('Progression').'</th><th>'.get_lang('MoyenneTest').'</th></tr>';
41
-	$header = array(get_lang('Course', ''), get_lang('TempsFrequentation', ''), get_lang('Progression', ''), get_lang('MoyenneTest', ''));
42
-	while ($a_course = Database::fetch_array($result_course)) {
43
-		// TODO: This query is to be checked, there are no HotPotatoes tests results.
44
-		$sql_moy_test = "SELECT exe_result,exe_weighting
36
+    if (isset($_POST['export'])) {
37
+        $export_result = export_csv($header, $data, 'test.csv'); // TODO: There is no data for exporting yet.
38
+        Display :: display_error_message($export_result);
39
+    }
40
+    echo '<table class="data_table"><tr><th>'.get_lang('Course').'</th><th>'.get_lang('TempsFrequentation').'</th><th>'.get_lang('Progression').'</th><th>'.get_lang('MoyenneTest').'</th></tr>';
41
+    $header = array(get_lang('Course', ''), get_lang('TempsFrequentation', ''), get_lang('Progression', ''), get_lang('MoyenneTest', ''));
42
+    while ($a_course = Database::fetch_array($result_course)) {
43
+        // TODO: This query is to be checked, there are no HotPotatoes tests results.
44
+        $sql_moy_test = "SELECT exe_result,exe_weighting
45 45
 			FROM $tbl_track_exercice
46 46
 			WHERE c_id = ".$a_course['id'];
47
-		$result_moy_test = Database::query($sql_moy_test);
48
-		$result = 0;
49
-		$weighting = 0;
50
-		while ($moy_test = Database::fetch_array($result_moy_test)) {
51
-			$result = $result + $moy_test['exe_result'];
52
-			$weighting = $weighting + $moy_test['exe_weighting'];
53
-		}
54
-		if ($weighting != 0) {
55
-			$moyenne_test = round(($result * 100) / $weighting);
56
-		} else {
57
-			$moyenne_test = null;
58
-		}
59
-		echo '<tr><td>'.$a_course['title'].'</td><td> </td><td> </td><td>'.(is_null($moyenne_test) ? '' : $moyenne_test.'%').'</td> </tr>';
60
-	}
61
-	echo '</table>';
62
-	echo "<br /><br />";
63
-	echo "<form method='post'><input type='submit' name='export' value='".get_lang('ExportExcel')."'/><form>";
47
+        $result_moy_test = Database::query($sql_moy_test);
48
+        $result = 0;
49
+        $weighting = 0;
50
+        while ($moy_test = Database::fetch_array($result_moy_test)) {
51
+            $result = $result + $moy_test['exe_result'];
52
+            $weighting = $weighting + $moy_test['exe_weighting'];
53
+        }
54
+        if ($weighting != 0) {
55
+            $moyenne_test = round(($result * 100) / $weighting);
56
+        } else {
57
+            $moyenne_test = null;
58
+        }
59
+        echo '<tr><td>'.$a_course['title'].'</td><td> </td><td> </td><td>'.(is_null($moyenne_test) ? '' : $moyenne_test.'%').'</td> </tr>';
60
+    }
61
+    echo '</table>';
62
+    echo "<br /><br />";
63
+    echo "<form method='post'><input type='submit' name='export' value='".get_lang('ExportExcel')."'/><form>";
64 64
 } else {
65
-	echo get_lang('NoCourse');
65
+    echo get_lang('NoCourse');
66 66
 }
67 67
 
68 68
 Display :: display_footer();
Please login to merge, or discard this patch.
main/mySpace/coaches.php 2 patches
Indentation   +77 added lines, -77 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@  discard block
 block discarded – undo
19 19
 $interbreadcrumb[] = array ("url" => "index.php", "name" => get_lang('MySpace'));
20 20
 
21 21
 if (isset($_GET["id_student"])) {
22
-	$interbreadcrumb[] = array ("url" => "student.php", "name" => get_lang('Students'));
22
+    $interbreadcrumb[] = array ("url" => "student.php", "name" => get_lang('Students'));
23 23
 }
24 24
 
25 25
 Display :: display_header($nameTools);
@@ -41,26 +41,26 @@  discard block
 block discarded – undo
41 41
  */
42 42
 
43 43
 if (isset($_POST['export'])) {
44
-	$order_clause = api_is_western_name_order(PERSON_NAME_DATA_EXPORT) ? ' ORDER BY firstname, lastname' : ' ORDER BY lastname, firstname';
44
+    $order_clause = api_is_western_name_order(PERSON_NAME_DATA_EXPORT) ? ' ORDER BY firstname, lastname' : ' ORDER BY lastname, firstname';
45 45
 } else {
46
-	$order_clause = api_sort_by_first_name() ? ' ORDER BY firstname, lastname' : ' ORDER BY lastname, firstname';
46
+    $order_clause = api_sort_by_first_name() ? ' ORDER BY firstname, lastname' : ' ORDER BY lastname, firstname';
47 47
 }
48 48
 
49 49
 if (isset($_GET["id_student"])) {
50
-	$id_student = intval($_GET["id_student"]);
51
-	$sql_coachs = "SELECT DISTINCT srcru.user_id as id_coach
50
+    $id_student = intval($_GET["id_student"]);
51
+    $sql_coachs = "SELECT DISTINCT srcru.user_id as id_coach
52 52
 		FROM $tbl_session_rel_course_rel_user as srcru
53 53
 		WHERE srcru.user_id='$id_student' AND srcru.status=2";
54 54
 } else {
55
-	if (api_is_platform_admin()) {
56
-		$sql_coachs = "SELECT DISTINCT
55
+    if (api_is_platform_admin()) {
56
+        $sql_coachs = "SELECT DISTINCT
57 57
 			srcru.user_id as id_coach, user_id, lastname, firstname
58 58
 			FROM $tbl_user, $tbl_session_rel_course_rel_user srcru
59 59
 			WHERE
60 60
 			 	srcru.user_id=user_id AND
61 61
 			 	srcru.status=2 ".$order_clause;
62
-	} else {
63
-		$sql_coachs = "SELECT DISTINCT user_id as id_coach, user.user_id, lastname, firstname
62
+    } else {
63
+        $sql_coachs = "SELECT DISTINCT user_id as id_coach, user.user_id, lastname, firstname
64 64
 			FROM
65 65
 			$tbl_user as user,
66 66
 			$tbl_session_rel_course_user as srcu,
@@ -74,13 +74,13 @@  discard block
 block discarded – undo
74 74
 				srcu.user_id = user.user_id AND
75 75
 				srcu.status = 2
76 76
 				".$order_clause;
77
-	}
77
+    }
78 78
 }
79 79
 
80 80
 $result_coachs = Database::query($sql_coachs);
81 81
 
82 82
 if (api_is_western_name_order()) {
83
-	echo '<table class="data_table">
83
+    echo '<table class="data_table">
84 84
 	    <tr>
85 85
             <th>'.get_lang('FirstName').'</th>
86 86
             <th>'.get_lang('LastName').'</th>
@@ -89,7 +89,7 @@  discard block
 block discarded – undo
89 89
             <th>'.get_lang('Students').'</th>
90 90
         </tr>';
91 91
 } else {
92
-	echo '<table class="data_table">
92
+    echo '<table class="data_table">
93 93
 	        <tr>
94 94
                 <th>'.get_lang('LastName').'</th>
95 95
                 <th>'.get_lang('FirstName').'</th>
@@ -100,79 +100,79 @@  discard block
 block discarded – undo
100 100
 }
101 101
 
102 102
 if (api_is_western_name_order(PERSON_NAME_DATA_EXPORT)) {
103
-	$header[] = get_lang('FirstName', '');
104
-	$header[] = get_lang('LastName', '');
103
+    $header[] = get_lang('FirstName', '');
104
+    $header[] = get_lang('LastName', '');
105 105
 } else {
106
-	$header[] = get_lang('LastName', '');
107
-	$header[] = get_lang('FirstName', '');
106
+    $header[] = get_lang('LastName', '');
107
+    $header[] = get_lang('FirstName', '');
108 108
 }
109 109
 $header[] = get_lang('ConnectionTime', '');
110 110
 
111 111
 if (Database::num_rows($result_coachs) > 0) {
112
-	while ($coachs = Database::fetch_array($result_coachs)) {
113
-		$id_coach = $coachs["id_coach"];
112
+    while ($coachs = Database::fetch_array($result_coachs)) {
113
+        $id_coach = $coachs["id_coach"];
114 114
 
115
-		if (isset($_GET["id_student"])) {
116
-			$sql_infos_coach = "SELECT lastname, firstname
115
+        if (isset($_GET["id_student"])) {
116
+            $sql_infos_coach = "SELECT lastname, firstname
117 117
             FROM $tbl_user
118 118
             WHERE user_id='$id_coach'";
119
-			$result_coachs_infos = Database::query($sql_infos_coach);
120
-			$lastname = Database::result($result_coachs_infos, 0, "lastname");
121
-			$firstname = Database::result($result_coachs_infos, 0, "firstname");
122
-		} else {
123
-			$lastname = $coachs["lastname"];
124
-			$firstname = $coachs["firstname"];
125
-		}
126
-
127
-		$sql_connection_time = "SELECT login_date, logout_date
119
+            $result_coachs_infos = Database::query($sql_infos_coach);
120
+            $lastname = Database::result($result_coachs_infos, 0, "lastname");
121
+            $firstname = Database::result($result_coachs_infos, 0, "firstname");
122
+        } else {
123
+            $lastname = $coachs["lastname"];
124
+            $firstname = $coachs["firstname"];
125
+        }
126
+
127
+        $sql_connection_time = "SELECT login_date, logout_date
128 128
         FROM $tbl_track_login
129 129
         WHERE login_user_id ='$id_coach' AND logout_date <> 'null'";
130
-		$result_connection_time = Database::query($sql_connection_time);
131
-
132
-		$nb_seconds = 0;
133
-		while ($connections = Database::fetch_array($result_connection_time)) {
134
-			$login_date = $connections["login_date"];
135
-			$logout_date = $connections["logout_date"];
136
-			$timestamp_login_date = strtotime($login_date);
137
-			$timestamp_logout_date = strtotime($logout_date);
138
-			$nb_seconds += ($timestamp_logout_date - $timestamp_login_date);
139
-		}
140
-
141
-		if ($nb_seconds == 0) {
142
-			$s_connection_time = '';
143
-		} else {
144
-			$s_connection_time = api_time_to_hms($nb_seconds);
145
-		}
146
-
147
-		if ($i % 2 == 0) {
148
-			$css_class = "row_odd";
149
-			if ($i % 20 == 0 && $i != 0) {
150
-				if (api_is_western_name_order()) {
151
-					echo '<tr>
130
+        $result_connection_time = Database::query($sql_connection_time);
131
+
132
+        $nb_seconds = 0;
133
+        while ($connections = Database::fetch_array($result_connection_time)) {
134
+            $login_date = $connections["login_date"];
135
+            $logout_date = $connections["logout_date"];
136
+            $timestamp_login_date = strtotime($login_date);
137
+            $timestamp_logout_date = strtotime($logout_date);
138
+            $nb_seconds += ($timestamp_logout_date - $timestamp_login_date);
139
+        }
140
+
141
+        if ($nb_seconds == 0) {
142
+            $s_connection_time = '';
143
+        } else {
144
+            $s_connection_time = api_time_to_hms($nb_seconds);
145
+        }
146
+
147
+        if ($i % 2 == 0) {
148
+            $css_class = "row_odd";
149
+            if ($i % 20 == 0 && $i != 0) {
150
+                if (api_is_western_name_order()) {
151
+                    echo '<tr>
152 152
 					    <th>'.get_lang('FirstName').'</th>
153 153
                         <th>'.get_lang('LastName').'</th>
154 154
                         <th>'.get_lang('ConnectionTime').'</th>
155 155
                         <th>'.get_lang('AdminCourses').'</th>
156 156
                         <th>'.get_lang('Students').'</th>
157 157
 					</tr>';
158
-				} else {
159
-					echo '<tr>
158
+                } else {
159
+                    echo '<tr>
160 160
 					    <th>'.get_lang('LastName').'</th>
161 161
                         <th>'.get_lang('FirstName').'</th>
162 162
                         <th>'.get_lang('ConnectionTime').'</th>
163 163
                         <th>'.get_lang('AdminCourses').'</th>
164 164
                         <th>'.get_lang('Students').'</th>
165 165
 					</tr>';
166
-				}
167
-			}
168
-		} else {
169
-			$css_class = "row_even";
170
-		}
166
+                }
167
+            }
168
+        } else {
169
+            $css_class = "row_even";
170
+        }
171 171
 
172
-		$i++;
172
+        $i++;
173 173
 
174
-		if (api_is_western_name_order()) {
175
-			echo '<tr class="'.$css_class.'">
174
+        if (api_is_western_name_order()) {
175
+            echo '<tr class="'.$css_class.'">
176 176
 			        <td>'.$firstname.'</td><td>'.$lastname.'</td><td>'.$s_connection_time.'</td>
177 177
 			        <td>
178 178
 			            <a href="course.php?type=coach&user_id='.$id_coach.'">
@@ -185,8 +185,8 @@  discard block
 block discarded – undo
185 185
 			            </a>
186 186
 			            </td>
187 187
                     </tr>';
188
-		} else {
189
-			echo '<tr class="'.$css_class.'">
188
+        } else {
189
+            echo '<tr class="'.$css_class.'">
190 190
 			        <td>'.$lastname.'</td><td>'.$firstname.'</td>
191 191
 			        <td>'.$s_connection_time.'</td>
192 192
 			        <td>
@@ -197,25 +197,25 @@  discard block
 block discarded – undo
197 197
                         '.Display::return_icon('2rightarrow.png', get_lang('Details')).'</a>
198 198
                     </td>
199 199
                     </tr>';
200
-		}
201
-
202
-		if (api_is_western_name_order(PERSON_NAME_DATA_EXPORT)) {
203
-			$data[$id_coach]["firstname"] = $firstname;
204
-			$data[$id_coach]["lastname"] = $lastname;
205
-		} else {
206
-			$data[$id_coach]["lastname"] = $lastname;
207
-			$data[$id_coach]["firstname"] = $firstname;
208
-		}
209
-		$data[$id_coach]["connection_time"] = $s_connection_time;
210
-	}
200
+        }
201
+
202
+        if (api_is_western_name_order(PERSON_NAME_DATA_EXPORT)) {
203
+            $data[$id_coach]["firstname"] = $firstname;
204
+            $data[$id_coach]["lastname"] = $lastname;
205
+        } else {
206
+            $data[$id_coach]["lastname"] = $lastname;
207
+            $data[$id_coach]["firstname"] = $firstname;
208
+        }
209
+        $data[$id_coach]["connection_time"] = $s_connection_time;
210
+    }
211 211
 } else {
212
-	// No results
213
-	echo '<tr><td colspan="5">'.get_lang("NoResult").'</td></tr>';
212
+    // No results
213
+    echo '<tr><td colspan="5">'.get_lang("NoResult").'</td></tr>';
214 214
 }
215 215
 echo '</table>';
216 216
 
217 217
 if (isset($_POST['export'])){
218
-	export_csv($header, $data, 'coaches.csv');
218
+    export_csv($header, $data, 'coaches.csv');
219 219
 }
220 220
 
221 221
 echo "<br /><br />";
Please login to merge, or discard this patch.
Spacing   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -16,10 +16,10 @@  discard block
 block discarded – undo
16 16
 $nameTools = get_lang('Tutors');
17 17
 
18 18
 api_block_anonymous_users();
19
-$interbreadcrumb[] = array ("url" => "index.php", "name" => get_lang('MySpace'));
19
+$interbreadcrumb[] = array("url" => "index.php", "name" => get_lang('MySpace'));
20 20
 
21 21
 if (isset($_GET["id_student"])) {
22
-	$interbreadcrumb[] = array ("url" => "student.php", "name" => get_lang('Students'));
22
+	$interbreadcrumb[] = array("url" => "student.php", "name" => get_lang('Students'));
23 23
 }
24 24
 
25 25
 Display :: display_header($nameTools);
@@ -27,14 +27,14 @@  discard block
 block discarded – undo
27 27
 api_display_tool_title($nameTools);
28 28
 
29 29
 // Database Table Definitions
30
-$tbl_course 						= Database :: get_main_table(TABLE_MAIN_COURSE);
31
-$tbl_course_user 					= Database :: get_main_table(TABLE_MAIN_COURSE_USER);
32
-$tbl_user 							= Database :: get_main_table(TABLE_MAIN_USER);
33
-$tbl_session 						= Database :: get_main_table(TABLE_MAIN_SESSION);
34
-$tbl_session_rel_course 			= Database :: get_main_table(TABLE_MAIN_SESSION_COURSE);
35
-$tbl_session_rel_course_rel_user 	= Database :: get_main_table(TABLE_MAIN_SESSION_COURSE_USER);
36
-$tbl_session_rel_user 				= Database :: get_main_table(TABLE_MAIN_SESSION_USER);
37
-$tbl_track_login 					= Database :: get_main_table(TABLE_STATISTIC_TRACK_E_LOGIN);
30
+$tbl_course = Database :: get_main_table(TABLE_MAIN_COURSE);
31
+$tbl_course_user = Database :: get_main_table(TABLE_MAIN_COURSE_USER);
32
+$tbl_user = Database :: get_main_table(TABLE_MAIN_USER);
33
+$tbl_session = Database :: get_main_table(TABLE_MAIN_SESSION);
34
+$tbl_session_rel_course = Database :: get_main_table(TABLE_MAIN_SESSION_COURSE);
35
+$tbl_session_rel_course_rel_user = Database :: get_main_table(TABLE_MAIN_SESSION_COURSE_USER);
36
+$tbl_session_rel_user = Database :: get_main_table(TABLE_MAIN_SESSION_USER);
37
+$tbl_track_login = Database :: get_main_table(TABLE_STATISTIC_TRACK_E_LOGIN);
38 38
 
39 39
 /**
40 40
  * MAIN PART
@@ -214,7 +214,7 @@  discard block
 block discarded – undo
214 214
 }
215 215
 echo '</table>';
216 216
 
217
-if (isset($_POST['export'])){
217
+if (isset($_POST['export'])) {
218 218
 	export_csv($header, $data, 'coaches.csv');
219 219
 }
220 220
 
@@ -222,8 +222,8 @@  discard block
 block discarded – undo
222 222
 echo "
223 223
     <br /><br />
224 224
     <form method='post' action='coaches.php'>
225
-        <button type='submit' class='save' name='export' value='" . get_lang('ExportExcel') . "'>
226
-            " . get_lang('ExportExcel') . "
225
+        <button type='submit' class='save' name='export' value='" . get_lang('ExportExcel')."'>
226
+            " . get_lang('ExportExcel')."
227 227
         </button>
228 228
     <form>
229 229
 ";
Please login to merge, or discard this patch.
main/mySpace/user_import.php 2 patches
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -15,12 +15,12 @@  discard block
 block discarded – undo
15 15
 $tool_name = get_lang('ImportUserListXMLCSV');
16 16
 api_block_anonymous_users();
17 17
 
18
-$interbreadcrumb[] = array ('url' => 'index.php', 'name' => get_lang('MySpace'));
18
+$interbreadcrumb[] = array('url' => 'index.php', 'name' => get_lang('MySpace'));
19 19
 $id_session = '';
20 20
 if (isset($_GET['id_session']) && $_GET['id_session'] != '') {
21 21
  	$id_session = intval($_GET['id_session']);
22
-	$interbreadcrumb[] = array ('url' => 'session.php', 'name' => get_lang('Sessions'));
23
-	$interbreadcrumb[] = array ('url' => 'course.php?id_session='.$id_session.'', 'name' => get_lang('Course'));
22
+	$interbreadcrumb[] = array('url' => 'session.php', 'name' => get_lang('Sessions'));
23
+	$interbreadcrumb[] = array('url' => 'course.php?id_session='.$id_session.'', 'name' => get_lang('Course'));
24 24
 }
25 25
 
26 26
 // Set this option to true to enforce strict purification for usenames.
@@ -62,7 +62,7 @@  discard block
 block discarded – undo
62 62
 
63 63
         if (count($errors) == 0) {
64 64
             if (!empty($id_session)) {
65
-                $tbl_session_rel_course	= Database::get_main_table(TABLE_MAIN_SESSION_COURSE);
65
+                $tbl_session_rel_course = Database::get_main_table(TABLE_MAIN_SESSION_COURSE);
66 66
                 // Selecting all the courses from the session id requested.
67 67
                 $sql = "SELECT c_id FROM $tbl_session_rel_course WHERE session_id ='$id_session'";
68 68
                 $result = Database::query($sql);
@@ -103,10 +103,10 @@  discard block
 block discarded – undo
103 103
 
104 104
 $form = new FormValidator('user_import');
105 105
 $form->addElement('hidden', 'formSent');
106
-$form->addElement('hidden', 'id_session',$id_session);
106
+$form->addElement('hidden', 'id_session', $id_session);
107 107
 $form->addElement('file', 'import_file', get_lang('ImportFileLocation'));
108 108
 $form->addRule('import_file', get_lang('ThisFieldIsRequired'), 'required');
109
-$allowed_file_types = array ('xml', 'csv');
109
+$allowed_file_types = array('xml', 'csv');
110 110
 $form->addRule('import_file', get_lang('InvalidExtension').' ('.implode(',', $allowed_file_types).')', 'filetype', $allowed_file_types);
111 111
 $form->addElement('radio', 'file_type', get_lang('FileType'), 'XML (<a href="../admin/example.xml" target="_blank">'.get_lang('ExampleXMLFile').'</a>)', 'xml');
112 112
 $form->addElement('radio', 'file_type', null, 'CSV (<a href="../admin/example.csv" target="_blank">'.get_lang('ExampleCSVFile').'</a>)', 'csv');
Please login to merge, or discard this patch.
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -18,9 +18,9 @@  discard block
 block discarded – undo
18 18
 $interbreadcrumb[] = array ('url' => 'index.php', 'name' => get_lang('MySpace'));
19 19
 $id_session = '';
20 20
 if (isset($_GET['id_session']) && $_GET['id_session'] != '') {
21
- 	$id_session = intval($_GET['id_session']);
22
-	$interbreadcrumb[] = array ('url' => 'session.php', 'name' => get_lang('Sessions'));
23
-	$interbreadcrumb[] = array ('url' => 'course.php?id_session='.$id_session.'', 'name' => get_lang('Course'));
21
+        $id_session = intval($_GET['id_session']);
22
+    $interbreadcrumb[] = array ('url' => 'session.php', 'name' => get_lang('Sessions'));
23
+    $interbreadcrumb[] = array ('url' => 'course.php?id_session='.$id_session.'', 'name' => get_lang('Course'));
24 24
 }
25 25
 
26 26
 // Set this option to true to enforce strict purification for usenames.
@@ -89,7 +89,7 @@  discard block
 block discarded – undo
89 89
 Display :: display_header($tool_name);
90 90
 
91 91
 if ($_FILES['import_file']['size'] == 0 && $_POST) {
92
-	Display::display_error_message(get_lang('ThisFieldIsRequired'));
92
+    Display::display_error_message(get_lang('ThisFieldIsRequired'));
93 93
 }
94 94
 
95 95
 if (count($errors) != 0) {
Please login to merge, or discard this patch.
main/mySpace/course.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -36,8 +36,8 @@
 block discarded – undo
36 36
 
37 37
 function count_courses()
38 38
 {
39
-	global $nb_courses;
40
-	return $nb_courses;
39
+    global $nb_courses;
40
+    return $nb_courses;
41 41
 }
42 42
 
43 43
 //checking if the current coach is the admin coach
Please login to merge, or discard this patch.
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -15,7 +15,7 @@  discard block
 block discarded – undo
15 15
 $sessionId = isset($_GET['session_id']) ? intval($_GET['session_id']) : null;
16 16
 
17 17
 api_block_anonymous_users();
18
-$interbreadcrumb[] = array ("url" => "index.php", "name" => get_lang('MySpace'));
18
+$interbreadcrumb[] = array("url" => "index.php", "name" => get_lang('MySpace'));
19 19
 
20 20
 if (isset($_GET["id_session"]) && $_GET["id_session"] != "") {
21 21
     $interbreadcrumb[] = array("url" => "session.php", "name" => get_lang('Sessions'));
@@ -66,7 +66,7 @@  discard block
 block discarded – undo
66 66
             $user_id = intval($_GET['user_id']);
67 67
             $user_info = api_get_user_info($user_id);
68 68
             $title = get_lang('AssignedCoursesTo').' '.api_get_person_name($user_info['firstname'], $user_info['lastname']);
69
-            $courses  = CourseManager::get_course_list_of_user_as_course_admin($user_id);
69
+            $courses = CourseManager::get_course_list_of_user_as_course_admin($user_id);
70 70
         } else {
71 71
             $title = get_lang('YourCourseList');
72 72
             $courses = CourseManager::get_courses_followed_by_drh(api_get_user_id());
@@ -81,7 +81,7 @@  discard block
 block discarded – undo
81 81
 
82 82
     if (!api_is_session_admin()) {
83 83
         $menu_items[] = Display::url(
84
-            Display::return_icon('stats.png', get_lang('MyStats'),'',ICON_SIZE_MEDIUM),
84
+            Display::return_icon('stats.png', get_lang('MyStats'), '', ICON_SIZE_MEDIUM),
85 85
             api_get_path(WEB_CODE_PATH)."auth/my_progress.php"
86 86
         );
87 87
         $menu_items[] = Display::url(
Please login to merge, or discard this patch.
main/mySpace/admin.php 1 patch
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -35,13 +35,13 @@  discard block
 block discarded – undo
35 35
 }
36 36
 $sql = "SELECT user.user_id,lastname,firstname,email
37 37
         FROM $tbl_user as user, $tbl_admin as admin
38
-        WHERE admin.user_id=user.user_id" . $order_clause;
38
+        WHERE admin.user_id=user.user_id".$order_clause;
39 39
 $result_admins = Database::query($sql);
40 40
 
41 41
 if (api_is_western_name_order()) {
42
-    echo '<table class="data_table"><tr><th>' . get_lang('FirstName') . '</th><th>' . get_lang('LastName') . '</th><th>' . get_lang('Email') . '</th></tr>';
42
+    echo '<table class="data_table"><tr><th>'.get_lang('FirstName').'</th><th>'.get_lang('LastName').'</th><th>'.get_lang('Email').'</th></tr>';
43 43
 } else {
44
-    echo '<table class="data_table"><tr><th>' . get_lang('LastName') . '</th><th>' . get_lang('FirstName') . '</th><th>' . get_lang('Email') . '</th></tr>';
44
+    echo '<table class="data_table"><tr><th>'.get_lang('LastName').'</th><th>'.get_lang('FirstName').'</th><th>'.get_lang('Email').'</th></tr>';
45 45
 }
46 46
 
47 47
 if (api_is_western_name_order(PERSON_NAME_DATA_EXPORT)) {
@@ -65,9 +65,9 @@  discard block
 block discarded – undo
65 65
             $css_class = "row_odd";
66 66
             if ($i % 20 == 0 && $i != 0) {
67 67
                 if (api_is_western_name_order()) {
68
-                    echo '<tr><th>' . get_lang('FirstName') . '</th><th>' . get_lang('LastName') . '</th><th>' . get_lang('Email') . '</th></tr>';
68
+                    echo '<tr><th>'.get_lang('FirstName').'</th><th>'.get_lang('LastName').'</th><th>'.get_lang('Email').'</th></tr>';
69 69
                 } else {
70
-                    echo '<tr><th>' . get_lang('LastName') . '</th><th>' . get_lang('FirstName') . '</th><th>' . get_lang('Email') . '</th></tr>';
70
+                    echo '<tr><th>'.get_lang('LastName').'</th><th>'.get_lang('FirstName').'</th><th>'.get_lang('Email').'</th></tr>';
71 71
                 }
72 72
             }
73 73
         } else {
@@ -77,9 +77,9 @@  discard block
 block discarded – undo
77 77
         $i++;
78 78
 
79 79
         if (api_is_western_name_order()) {
80
-            echo "<tr class=" . $css_class . "><td>$firstname</td><td>$lastname</td><td><a href='mailto:" . $email . "'>$email</a></td></tr>";
80
+            echo "<tr class=".$css_class."><td>$firstname</td><td>$lastname</td><td><a href='mailto:".$email."'>$email</a></td></tr>";
81 81
         } else {
82
-            echo "<tr class=" . $css_class . "><td>$lastname</td><td>$firstname</td><td><a href='mailto:" . $email . "'>$email</a></td></tr>";
82
+            echo "<tr class=".$css_class."><td>$lastname</td><td>$firstname</td><td><a href='mailto:".$email."'>$email</a></td></tr>";
83 83
         }
84 84
 
85 85
         if (api_is_western_name_order(PERSON_NAME_DATA_EXPORT)) {
@@ -93,7 +93,7 @@  discard block
 block discarded – undo
93 93
     }
94 94
 } else {
95 95
     // No results
96
-    echo '<tr><td colspan="3">' . get_lang('NoResults') . '</td></tr>';
96
+    echo '<tr><td colspan="3">'.get_lang('NoResults').'</td></tr>';
97 97
 }
98 98
 echo '</table>';
99 99
 
@@ -104,8 +104,8 @@  discard block
 block discarded – undo
104 104
 echo "
105 105
     <br /><br />
106 106
     <form method='post' action='admin.php'>
107
-        <button type='submit' class='save' name='export' value='" . get_lang('ExportExcel') . "'>
108
-            " . get_lang('ExportExcel') . "
107
+        <button type='submit' class='save' name='export' value='" . get_lang('ExportExcel')."'>
108
+            " . get_lang('ExportExcel')."
109 109
         </button>
110 110
     <form>
111 111
 ";
Please login to merge, or discard this patch.
main/mySpace/access_details.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -138,7 +138,7 @@
 block discarded – undo
138 138
     </div><br />
139 139
     <div id="cev_cont_stats">
140 140
     <?php
141
-    if ($result_to_print != "")  {
141
+    if ($result_to_print != "") {
142 142
         $rst = get_stats($user_id, $courseId);
143 143
         $foo_stats = '<strong>'.get_lang('Total').': </strong>'.$rst['total'].'<br />';
144 144
         $foo_stats .= '<strong>'.get_lang('Average').': </strong>'.$rst['avg'].'<br />';
Please login to merge, or discard this patch.
main/wiki/diff.inc.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -137,19 +137,19 @@  discard block
 block discarded – undo
137 137
     switch ($type) {
138 138
         case DIFF_EQUAL:
139 139
             // return $line. ' : ' . ' = <span class="diffEqual" >' . $value . '</span><br />' . "\n" ;
140
-            return '<span class="diffEqual" >' . $value . '</span><br />' . "\n"; //juan carlos muestra solo color
140
+            return '<span class="diffEqual" >'.$value.'</span><br />'."\n"; //juan carlos muestra solo color
141 141
             break;
142 142
         case DIFF_MOVED:
143 143
             //return $line. ' : ' . ' M <span class="diffMoved" >' . $value . '</span><br />' . "\n" ; //juan carlos ra�a  la sustitye la inverior
144
-            return '<span class="diffMoved" >' . $value . '</span><br />' . "\n"; //juan carlos muestra solo color
144
+            return '<span class="diffMoved" >'.$value.'</span><br />'."\n"; //juan carlos muestra solo color
145 145
             break;
146 146
         case DIFF_ADDED:
147 147
             //return $line . ' : ' . ' + <span class="diffAdded" >' . $value . '</span><br />' . "\n" ;
148
-            return '<span class="diffAdded" >' . $value . '</span><br />' . "\n"; //juan carlos muestra solo color
148
+            return '<span class="diffAdded" >'.$value.'</span><br />'."\n"; //juan carlos muestra solo color
149 149
             break;
150 150
         case DIFF_DELETED:
151 151
             //return $line . ' : ' . ' - <span class="diffDeleted" >' . $value . '</span><br />' . "\n" ; //juan carlos ra�a  la sustitye la inverior
152
-            return '<span class="diffDeleted" >' . $value . '</span><br />' . "\n"; //juan carlos muestra solo color
152
+            return '<span class="diffDeleted" >'.$value.'</span><br />'."\n"; //juan carlos muestra solo color
153 153
             break;
154 154
     }
155 155
 }
@@ -169,19 +169,19 @@  discard block
 block discarded – undo
169 169
     switch ($type) {
170 170
         case DIFF_EQUAL:
171 171
             //return '<tr><td>' . $line. '&nbsp;:&nbsp;' . '&nbsp;=</td><td><span class="diffEqual" >'                    . $value . '</span></td></tr>' . "\n"; //juan carlos comentado
172
-            return '<tr><td></td><td bgcolor="#FFFFFF">' . $value . '</td></tr>' . "\n"; //juan carlos muestra solo color (no tambi�n la l�nea). Adem�s EN IEXPLORER VA BIEN PERO EN FIREFOX 3 la etiqueta span no muestra el color de fondo que est� definido en la hoja de estilos como background-color, aceptando s�lo la propiedad color pero esta solo da color al texto con lo cual los cambios quedan poco resaltados, adem�s los cambios de otros objetos que no sean texto no se indican por ej. a�adir una imagen, por esta raz�n doy el color de fondo al td directamente.
172
+            return '<tr><td></td><td bgcolor="#FFFFFF">'.$value.'</td></tr>'."\n"; //juan carlos muestra solo color (no tambi�n la l�nea). Adem�s EN IEXPLORER VA BIEN PERO EN FIREFOX 3 la etiqueta span no muestra el color de fondo que est� definido en la hoja de estilos como background-color, aceptando s�lo la propiedad color pero esta solo da color al texto con lo cual los cambios quedan poco resaltados, adem�s los cambios de otros objetos que no sean texto no se indican por ej. a�adir una imagen, por esta raz�n doy el color de fondo al td directamente.
173 173
             break;
174 174
         case DIFF_MOVED:
175 175
             // return '<tr><td>' . $line. '&nbsp;:&nbsp;' . '&nbsp;M</td><td><span class="diffMoved" >'                    . $value . '</span></td></tr>' . "\n" //juan carlos comenta
176 176
 
177
-            return '<tr><td></td><td bgcolor="#FFFFAA">' . $value . '</td></tr>' . "\n"; //juan carlos muestra solo color (no tambi�n la l�nea). Adem�s EN IEXPLORER VA BIEN PERO EN FIREFOX 3 la etiqueta span no muestra el color de fondo que est� definido en la hoja de estilos como background-color, aceptando s�lo la propiedad color pero esta solo da color al texto con lo cual los cambios quedan poco resaltados, adem�s los cambios de otros objetos que no sean texto no se indican por ej. a�adir una imagen, por esta raz�n doy el color de fondo al td directamente.
177
+            return '<tr><td></td><td bgcolor="#FFFFAA">'.$value.'</td></tr>'."\n"; //juan carlos muestra solo color (no tambi�n la l�nea). Adem�s EN IEXPLORER VA BIEN PERO EN FIREFOX 3 la etiqueta span no muestra el color de fondo que est� definido en la hoja de estilos como background-color, aceptando s�lo la propiedad color pero esta solo da color al texto con lo cual los cambios quedan poco resaltados, adem�s los cambios de otros objetos que no sean texto no se indican por ej. a�adir una imagen, por esta raz�n doy el color de fondo al td directamente.
178 178
             break;
179 179
         case DIFF_ADDED:
180 180
             // return '<tr><td>' . $line. '&nbsp;:&nbsp;' . '&nbsp;+</td><td><span class="diffAdded" >'                    . $value . '</span></td></tr>' . "\n" ; //juan carlos comentado
181
-            return '<tr><td></td><td bgcolor="#CCFFCC">' . $value . '</td></tr>' . "\n"; //juan carlos muestra solo color (no tambi�n la l�nea). Adem�s EN IEXPLORER VA BIEN PERO EN FIREFOX 3 la etiqueta span no muestra el color de fondo que est� definido en la hoja de estilos como background-color, aceptando s�lo la propiedad color pero esta solo da color al texto con lo cual los cambios quedan poco resaltados, adem�s los cambios de otros objetos que no sean texto no se indican por ej. a�adir una imagen, por esta raz�n doy el color de fondo al td directamente.
181
+            return '<tr><td></td><td bgcolor="#CCFFCC">'.$value.'</td></tr>'."\n"; //juan carlos muestra solo color (no tambi�n la l�nea). Adem�s EN IEXPLORER VA BIEN PERO EN FIREFOX 3 la etiqueta span no muestra el color de fondo que est� definido en la hoja de estilos como background-color, aceptando s�lo la propiedad color pero esta solo da color al texto con lo cual los cambios quedan poco resaltados, adem�s los cambios de otros objetos que no sean texto no se indican por ej. a�adir una imagen, por esta raz�n doy el color de fondo al td directamente.
182 182
             break;
183 183
         case DIFF_DELETED:
184 184
             // return '<tr><td>' . $line. '&nbsp;:&nbsp;' . '&nbsp;-</td><td><span class="diffDeleted" >'                    . $value . '</span></td></tr>' . "\n" ; //juan carlos comentado
185
-            return '<tr><td></td><td bgcolor="#FFAAAA">' . $value . '</td></tr>' . "\n"; //juan carlos muestra solo color (no tambi�n la l�nea). Adem�s EN IEXPLORER VA BIEN PERO EN FIREFOX 3 la etiqueta span no muestra el color de fondo que est� definido en la hoja de estilos como background-color, aceptando s�lo la propiedad color pero esta solo da color al texto con lo cual los cambios quedan poco resaltados, adem�s los cambios de otros objetos que no sean texto no se indican por ej. a�adir una imagen, por esta raz�n doy el color de fondo al td directamente.
185
+            return '<tr><td></td><td bgcolor="#FFAAAA">'.$value.'</td></tr>'."\n"; //juan carlos muestra solo color (no tambi�n la l�nea). Adem�s EN IEXPLORER VA BIEN PERO EN FIREFOX 3 la etiqueta span no muestra el color de fondo que est� definido en la hoja de estilos como background-color, aceptando s�lo la propiedad color pero esta solo da color al texto con lo cual los cambios quedan poco resaltados, adem�s los cambios de otros objetos que no sean texto no se indican por ej. a�adir una imagen, por esta raz�n doy el color de fondo al td directamente.
186 186
     }
187 187
 }
Please login to merge, or discard this patch.