Completed
Branch develop (87e03b)
by
unknown
18:24
created
htdocs/public/company/new.php 1 patch
Spacing   +69 added lines, -69 removed lines patch added patch discarded remove patch
@@ -51,15 +51,15 @@  discard block
 block discarded – undo
51 51
 
52 52
 // Load Dolibarr environment
53 53
 require '../../main.inc.php';
54
-require_once DOL_DOCUMENT_ROOT . '/core/lib/company.lib.php';
55
-require_once DOL_DOCUMENT_ROOT . '/core/lib/payments.lib.php';
56
-require_once DOL_DOCUMENT_ROOT . '/adherents/class/adherent.class.php';
57
-require_once DOL_DOCUMENT_ROOT . '/adherents/class/adherent_type.class.php';
58
-require_once DOL_DOCUMENT_ROOT . '/core/class/extrafields.class.php';
59
-require_once DOL_DOCUMENT_ROOT . '/core/class/html.formcompany.class.php';
60
-require_once DOL_DOCUMENT_ROOT . '/core/class/cunits.class.php';
61
-require_once DOL_DOCUMENT_ROOT . '/core/lib/date.lib.php';
62
-require_once DOL_DOCUMENT_ROOT . '/core/class/html.formadmin.class.php';
54
+require_once DOL_DOCUMENT_ROOT.'/core/lib/company.lib.php';
55
+require_once DOL_DOCUMENT_ROOT.'/core/lib/payments.lib.php';
56
+require_once DOL_DOCUMENT_ROOT.'/adherents/class/adherent.class.php';
57
+require_once DOL_DOCUMENT_ROOT.'/adherents/class/adherent_type.class.php';
58
+require_once DOL_DOCUMENT_ROOT.'/core/class/extrafields.class.php';
59
+require_once DOL_DOCUMENT_ROOT.'/core/class/html.formcompany.class.php';
60
+require_once DOL_DOCUMENT_ROOT.'/core/class/cunits.class.php';
61
+require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php';
62
+require_once DOL_DOCUMENT_ROOT.'/core/class/html.formadmin.class.php';
63 63
 // Init vars
64 64
 $backtopage = GETPOST('backtopage', 'alpha');
65 65
 $action = GETPOST('action', 'aZ09');
@@ -83,7 +83,7 @@  discard block
 block discarded – undo
83 83
 
84 84
 //permissions
85 85
 
86
-$permissiontoadd 	= $user->hasRight('societe', 'creer');
86
+$permissiontoadd = $user->hasRight('societe', 'creer');
87 87
 
88 88
 // Initialize technical object to manage hooks of page. Note that conf->hooks_modules contains array of hook context
89 89
 $hookmanager->initHooks(array('publicnewmembercard', 'globalcard'));
@@ -115,14 +115,14 @@  discard block
 block discarded – undo
115 115
 	print '<body id="mainbody" class="publicnewmemberform">';
116 116
 
117 117
 	// Define urllogo
118
-	$urllogo = DOL_URL_ROOT . '/theme/common/login_logo.png';
119
-
120
-	if (!empty($mysoc->logo_small) && is_readable($conf->mycompany->dir_output . '/logos/thumbs/' . $mysoc->logo_small)) {
121
-		$urllogo = DOL_URL_ROOT . '/viewimage.php?cache=1&amp;modulepart=mycompany&amp;file=' . urlencode('logos/thumbs/' . $mysoc->logo_small);
122
-	} elseif (!empty($mysoc->logo) && is_readable($conf->mycompany->dir_output . '/logos/' . $mysoc->logo)) {
123
-		$urllogo = DOL_URL_ROOT . '/viewimage.php?cache=1&amp;modulepart=mycompany&amp;file=' . urlencode('logos/' . $mysoc->logo);
124
-	} elseif (is_readable(DOL_DOCUMENT_ROOT . '/theme/dolibarr_logo.svg')) {
125
-		$urllogo = DOL_URL_ROOT . '/theme/dolibarr_logo.svg';
118
+	$urllogo = DOL_URL_ROOT.'/theme/common/login_logo.png';
119
+
120
+	if (!empty($mysoc->logo_small) && is_readable($conf->mycompany->dir_output.'/logos/thumbs/'.$mysoc->logo_small)) {
121
+		$urllogo = DOL_URL_ROOT.'/viewimage.php?cache=1&amp;modulepart=mycompany&amp;file='.urlencode('logos/thumbs/'.$mysoc->logo_small);
122
+	} elseif (!empty($mysoc->logo) && is_readable($conf->mycompany->dir_output.'/logos/'.$mysoc->logo)) {
123
+		$urllogo = DOL_URL_ROOT.'/viewimage.php?cache=1&amp;modulepart=mycompany&amp;file='.urlencode('logos/'.$mysoc->logo);
124
+	} elseif (is_readable(DOL_DOCUMENT_ROOT.'/theme/dolibarr_logo.svg')) {
125
+		$urllogo = DOL_URL_ROOT.'/theme/dolibarr_logo.svg';
126 126
 	}
127 127
 
128 128
 	print '<header class="center">';
@@ -131,17 +131,17 @@  discard block
 block discarded – undo
131 131
 	if ($urllogo) {
132 132
 		print '<div class="backgreypublicpayment">';
133 133
 		print '<div class="logopublicpayment">';
134
-		print '<img id="dolpaymentlogo" src="' . $urllogo . '">';
134
+		print '<img id="dolpaymentlogo" src="'.$urllogo.'">';
135 135
 		print '</div>';
136 136
 		if (!getDolGlobalString('MAIN_HIDE_POWERED_BY')) {
137
-			print '<div class="poweredbypublicpayment opacitymedium right"><a class="poweredbyhref" href="https://www.dolibarr.org?utm_medium=website&utm_source=poweredby" target="dolibarr" rel="noopener">' . $langs->trans("PoweredBy") . '<br><img class="poweredbyimg" src="' . DOL_URL_ROOT . '/theme/dolibarr_logo.svg" width="80px"></a></div>';
137
+			print '<div class="poweredbypublicpayment opacitymedium right"><a class="poweredbyhref" href="https://www.dolibarr.org?utm_medium=website&utm_source=poweredby" target="dolibarr" rel="noopener">'.$langs->trans("PoweredBy").'<br><img class="poweredbyimg" src="'.DOL_URL_ROOT.'/theme/dolibarr_logo.svg" width="80px"></a></div>';
138 138
 		}
139 139
 		print '</div>';
140 140
 	}
141 141
 
142 142
 	if (getDolGlobalString('MEMBER_IMAGE_PUBLIC_REGISTRATION')) {
143 143
 		print '<div class="backimagepublicregistration">';
144
-		print '<img id="idEVENTORGANIZATION_IMAGE_PUBLIC_INTERFACE" src="' . getDolGlobalString('MEMBER_IMAGE_PUBLIC_REGISTRATION') . '">';
144
+		print '<img id="idEVENTORGANIZATION_IMAGE_PUBLIC_INTERFACE" src="'.getDolGlobalString('MEMBER_IMAGE_PUBLIC_REGISTRATION').'">';
145 145
 		print '</div>';
146 146
 	}
147 147
 
@@ -166,8 +166,8 @@  discard block
 block discarded – undo
166 166
 	printCommonFooter('public');
167 167
 
168 168
 	if (!empty($conf->use_javascript_ajax)) {
169
-		print "\n" . '<!-- Includes JS Footer of Dolibarr -->' . "\n";
170
-		print '<script src="' . DOL_URL_ROOT . '/core/js/lib_foot.js.php?lang=' . $langs->defaultlang . (!empty($ext) ? '&' . $ext : '') . '"></script>' . "\n";
169
+		print "\n".'<!-- Includes JS Footer of Dolibarr -->'."\n";
170
+		print '<script src="'.DOL_URL_ROOT.'/core/js/lib_foot.js.php?lang='.$langs->defaultlang.(!empty($ext) ? '&'.$ext : '').'"></script>'."\n";
171 171
 	}
172 172
 
173 173
 	print "</body>\n";
@@ -205,7 +205,7 @@  discard block
 block discarded – undo
205 205
 		$ok = (array_key_exists($sessionkey, $_SESSION) === true && (strtolower($_SESSION[$sessionkey]) == strtolower($_POST['code'])));
206 206
 		if (!$ok) {
207 207
 			$error++;
208
-			$errmsg .= $langs->trans("ErrorBadValueForCode") . "<br>\n";
208
+			$errmsg .= $langs->trans("ErrorBadValueForCode")."<br>\n";
209 209
 			$action = '';
210 210
 		}
211 211
 	}
@@ -217,19 +217,19 @@  discard block
 block discarded – undo
217 217
 
218 218
 		$societe->client = GETPOST('client', 'int') ? GETPOST('client', 'int') : $societe->client;
219 219
 
220
-		$societe->address	= GETPOST('address', 'alphanohtml');
220
+		$societe->address = GETPOST('address', 'alphanohtml');
221 221
 
222
-		$societe->country_id				= GETPOSTINT('country_id');
222
+		$societe->country_id = GETPOSTINT('country_id');
223 223
 
224
-		$societe->phone					= GETPOST('phone', 'alpha');
224
+		$societe->phone = GETPOST('phone', 'alpha');
225 225
 
226
-		$societe->fax				= GETPOST('fax', 'alpha');
226
+		$societe->fax = GETPOST('fax', 'alpha');
227 227
 
228
-		$societe->email					= trim(GETPOST('email', 'custom', 0, FILTER_SANITIZE_EMAIL));
228
+		$societe->email = trim(GETPOST('email', 'custom', 0, FILTER_SANITIZE_EMAIL));
229 229
 
230
-		$societe->client = 2 ; // our client is a prospect
230
+		$societe->client = 2; // our client is a prospect
231 231
 
232
-		$societe->code_client		= '-1';
232
+		$societe->code_client = '-1';
233 233
 
234 234
 		$societe->name_alias = GETPOST('name_alias', 'alphanohtml');
235 235
 
@@ -237,7 +237,7 @@  discard block
 block discarded – undo
237 237
 		if (!$error) {
238 238
 			$result = $societe->create($user);
239 239
 			if ($result > 0) {
240
-				require_once DOL_DOCUMENT_ROOT . '/core/class/CMailFile.class.php';
240
+				require_once DOL_DOCUMENT_ROOT.'/core/class/CMailFile.class.php';
241 241
 				$objectsoc = $societe;
242 242
 
243 243
 				if (!empty($backtopage)) {
@@ -246,7 +246,7 @@  discard block
 block discarded – undo
246 246
 					$urlback = getDolGlobalString('MEMBER_URL_REDIRECT_SUBSCRIPTION');
247 247
 					// TODO Make replacement of __AMOUNT__, etc...
248 248
 				} else {
249
-					$urlback = $_SERVER["PHP_SELF"] . "?action=added&token=" . newToken();
249
+					$urlback = $_SERVER["PHP_SELF"]."?action=added&token=".newToken();
250 250
 				}
251 251
 			} else {
252 252
 				$error++;
@@ -258,7 +258,7 @@  discard block
 block discarded – undo
258 258
 	if (!$error) {
259 259
 		$db->commit();
260 260
 
261
-		header("Location: " . $urlback);
261
+		header("Location: ".$urlback);
262 262
 		exit;
263 263
 	} else {
264 264
 		$db->rollback();
@@ -299,7 +299,7 @@  discard block
 block discarded – undo
299 299
 llxHeaderVierge($langs->trans("ContactUs"));
300 300
 
301 301
 print '<br>';
302
-print load_fiche_titre(img_picto('', 'member_nocolor', 'class="pictofixedwidth"') . ' &nbsp; ' . $langs->trans("ContactUs"), '', '', 0, 0, 'center');
302
+print load_fiche_titre(img_picto('', 'member_nocolor', 'class="pictofixedwidth"').' &nbsp; '.$langs->trans("ContactUs"), '', '', 0, 0, 'center');
303 303
 
304 304
 
305 305
 print '<div align="center">';
@@ -307,9 +307,9 @@  discard block
 block discarded – undo
307 307
 
308 308
 print '<div class="center subscriptionformhelptext opacitymedium justify">';
309 309
 if (getDolGlobalString('COMPANY_NEWFORM_TEXT')) {
310
-	print $langs->trans(getDolGlobalString('COMPANY_NEWFORM_TEXT')) . "<br>\n";
310
+	print $langs->trans(getDolGlobalString('COMPANY_NEWFORM_TEXT'))."<br>\n";
311 311
 } else {
312
-	print $langs->trans("ContactUsDesc", getDolGlobalString("MAIN_INFO_SOCIETE_MAIL")) . "<br>\n";
312
+	print $langs->trans("ContactUsDesc", getDolGlobalString("MAIN_INFO_SOCIETE_MAIL"))."<br>\n";
313 313
 }
314 314
 print '</div>';
315 315
 
@@ -317,13 +317,13 @@  discard block
 block discarded – undo
317 317
 dol_htmloutput_events();
318 318
 
319 319
 // Print form
320
-print '<form action="' . $_SERVER["PHP_SELF"] . '" method="POST" name="newprospect">' . "\n";
321
-print '<input type="hidden" name="token" value="' . newToken() . '" / >';
322
-print '<input type="hidden" name="entity" value="' . $entity . '" />';
320
+print '<form action="'.$_SERVER["PHP_SELF"].'" method="POST" name="newprospect">'."\n";
321
+print '<input type="hidden" name="token" value="'.newToken().'" / >';
322
+print '<input type="hidden" name="entity" value="'.$entity.'" />';
323 323
 print '<input type="hidden" name="action" value="add" />';
324 324
 print '<br>';
325 325
 
326
-$messagemandatory = '<span class="">' . $langs->trans("FieldsWithAreMandatory", '*') . '</span>';
326
+$messagemandatory = '<span class="">'.$langs->trans("FieldsWithAreMandatory", '*').'</span>';
327 327
 //print '<br><span class="opacitymedium">'.$langs->trans("FieldsWithAreMandatory", '*').'</span><br>';
328 328
 //print $langs->trans("FieldsWithIsForPublic",'**').'<br>';
329 329
 
@@ -359,7 +359,7 @@  discard block
 block discarded – undo
359 359
 </script>';
360 360
 
361 361
 
362
-print '<table class="border" summary="form to subscribe" id="tablesubscribe">' . "\n";
362
+print '<table class="border" summary="form to subscribe" id="tablesubscribe">'."\n";
363 363
 //Third party name
364 364
 /*
365 365
 if ($objectsoc->particulier || $private) {
@@ -369,30 +369,30 @@  discard block
 block discarded – undo
369 369
 }
370 370
 */
371 371
 print '<tr class="tr-field-thirdparty-name"><td class="titlefieldcreate">'; // text appreas left
372
-print '<input type="hidden" name="ThirdPartyName" value="' . $langs->trans('ThirdPartyName') . '">';
373
-print '<span id="TypeName" class="fieldrequired"  title="' .dol_escape_htmltag($langs->trans("FieldsWithAreMandatory", '*')) . '" >' . $form->editfieldkey('Company', 'name', '', $objectsoc, 0) . '<span class="star"> *</span></span>';
372
+print '<input type="hidden" name="ThirdPartyName" value="'.$langs->trans('ThirdPartyName').'">';
373
+print '<span id="TypeName" class="fieldrequired"  title="'.dol_escape_htmltag($langs->trans("FieldsWithAreMandatory", '*')).'" >'.$form->editfieldkey('Company', 'name', '', $objectsoc, 0).'<span class="star"> *</span></span>';
374 374
 print '</td><td>'; // inline input
375
-print '<input type="text" class="minwidth300" maxlength="128" name="name" id="name" value="' . dol_escape_htmltag($objectsoc->name) . '" autofocus="autofocus">';
375
+print '<input type="text" class="minwidth300" maxlength="128" name="name" id="name" value="'.dol_escape_htmltag($objectsoc->name).'" autofocus="autofocus">';
376 376
 //
377 377
 
378 378
 // Name and lastname
379
-print '<tr><td class="classfortooltip" title="' . dol_escape_htmltag($messagemandatory) . '">' . $langs->trans("Firstname") . ' <span class="star">*</span></td><td><input type="text" name="firstname" class="minwidth150" value="' . dol_escape_htmltag(GETPOST('firstname')) . '"></td></tr>' . "\n";
379
+print '<tr><td class="classfortooltip" title="'.dol_escape_htmltag($messagemandatory).'">'.$langs->trans("Firstname").' <span class="star">*</span></td><td><input type="text" name="firstname" class="minwidth150" value="'.dol_escape_htmltag(GETPOST('firstname')).'"></td></tr>'."\n";
380 380
 
381
-print '<tr><td class="classfortooltip" title="' . dol_escape_htmltag($messagemandatory) . '">' . $langs->trans("Lastname") . ' <span class="star">*</span></td><td><input type="text" name="lastname" class="minwidth150" value="' . dol_escape_htmltag(GETPOST('lastname')) . '"></td></tr>' . "\n";
381
+print '<tr><td class="classfortooltip" title="'.dol_escape_htmltag($messagemandatory).'">'.$langs->trans("Lastname").' <span class="star">*</span></td><td><input type="text" name="lastname" class="minwidth150" value="'.dol_escape_htmltag(GETPOST('lastname')).'"></td></tr>'."\n";
382 382
 
383 383
 // Address
384 384
 print '<tr><td class="tdtop">';
385 385
 print $form->editfieldkey('Address', 'address', '', $objectsoc, 0);
386 386
 print '</td>';
387 387
 print '<td>';
388
-print '<textarea name="address" id="address" class="quatrevingtpercent" rows="' . ROWS_2 . '" wrap="soft">';
388
+print '<textarea name="address" id="address" class="quatrevingtpercent" rows="'.ROWS_2.'" wrap="soft">';
389 389
 print dol_escape_htmltag($objectsoc->address, 0, 1);
390 390
 print '</textarea>';
391 391
 print $form->widgetForTranslation("address", $objectsoc, $permissiontoadd, 'textarea', 'alphanohtml', 'quatrevingtpercent');
392 392
 print '</td></tr>';
393 393
 
394 394
 // Country
395
-print '<tr><td>' . $form->editfieldkey('Country', 'selectcountry_id', '', $objectsoc, 0) . '</td><td class="maxwidthonsmartphone">';
395
+print '<tr><td>'.$form->editfieldkey('Country', 'selectcountry_id', '', $objectsoc, 0).'</td><td class="maxwidthonsmartphone">';
396 396
 print img_picto('', 'country', 'class="pictofixedwidth"');
397 397
 print $form->select_country((GETPOSTISSET('country_id') ? GETPOST('country_id') : $objectsoc->country_id), 'country_id', '', 0, 'minwidth300 maxwidth500 widthcentpercentminusx');
398 398
 if ($user->admin) {
@@ -401,50 +401,50 @@  discard block
 block discarded – undo
401 401
 print '</td></tr>';
402 402
 
403 403
 // Phone / Fax
404
-print '<tr><td>' . $form->editfieldkey('Phone', 'phone', '', $objectsoc, 0) . '</td>';
405
-print '<td>' . img_picto('', 'object_phoning', 'class="pictofixedwidth"') . ' <input type="text" name="phone" id="phone" class="maxwidth200 widthcentpercentminusx" value="' . (GETPOSTISSET('phone') ? GETPOST('phone', 'alpha') : $objectsoc->phone) . '"></td>';
404
+print '<tr><td>'.$form->editfieldkey('Phone', 'phone', '', $objectsoc, 0).'</td>';
405
+print '<td>'.img_picto('', 'object_phoning', 'class="pictofixedwidth"').' <input type="text" name="phone" id="phone" class="maxwidth200 widthcentpercentminusx" value="'.(GETPOSTISSET('phone') ? GETPOST('phone', 'alpha') : $objectsoc->phone).'"></td>';
406 406
 print '</tr>';
407 407
 
408 408
 print '<tr>';
409
-print '<td>' . $form->editfieldkey('Fax', 'fax', '', $objectsoc, 0) . '</td>';
410
-print '<td>' . img_picto('', 'object_phoning_fax', 'class="pictofixedwidth"') . ' <input type="text" name="fax" id="fax" class="maxwidth200 widthcentpercentminusx" value="' . (GETPOSTISSET('fax') ? GETPOST('fax', 'alpha') : $objectsoc->fax) . '"></td>';
409
+print '<td>'.$form->editfieldkey('Fax', 'fax', '', $objectsoc, 0).'</td>';
410
+print '<td>'.img_picto('', 'object_phoning_fax', 'class="pictofixedwidth"').' <input type="text" name="fax" id="fax" class="maxwidth200 widthcentpercentminusx" value="'.(GETPOSTISSET('fax') ? GETPOST('fax', 'alpha') : $objectsoc->fax).'"></td>';
411 411
 print '</tr>';
412 412
 
413 413
 // Email / Web
414
-print '<tr><td>' . $form->editfieldkey('EMail', 'email', '', $objectsoc, 0, 'string', '', !getDolGlobalString('SOCIETE_EMAIL_MANDATORY') ? '' : $conf->global->SOCIETE_EMAIL_MANDATORY) . '</td>';
415
-print '<td>' . img_picto('', 'object_email', 'class="pictofixedwidth"') . ' <input type="text" class="maxwidth200 widthcentpercentminusx" name="email" id="email" value="' . $objectsoc->email . '"></td>';
414
+print '<tr><td>'.$form->editfieldkey('EMail', 'email', '', $objectsoc, 0, 'string', '', !getDolGlobalString('SOCIETE_EMAIL_MANDATORY') ? '' : $conf->global->SOCIETE_EMAIL_MANDATORY).'</td>';
415
+print '<td>'.img_picto('', 'object_email', 'class="pictofixedwidth"').' <input type="text" class="maxwidth200 widthcentpercentminusx" name="email" id="email" value="'.$objectsoc->email.'"></td>';
416 416
 if (isModEnabled('mailing') && getDolGlobalString('THIRDPARTY_SUGGEST_ALSO_ADDRESS_CREATION')) {
417 417
 	if ($conf->browser->layout == 'phone') {
418 418
 		print '</tr><tr>';
419 419
 	}
420
-	print '<td class="individualline noemail">' . $form->editfieldkey($langs->trans('No_Email') . ' (' . $langs->trans('Contact') . ')', 'contact_no_email', '', $objectsoc, 0) . '</td>';
421
-	print '<td class="individualline" ' . (($conf->browser->layout == 'phone') || !isModEnabled('mailing') ? ' colspan="3"' : '') . '>' . $form->selectyesno('contact_no_email', (GETPOSTISSET("contact_no_email") ? GETPOST("contact_no_email", 'alpha') : (empty($objectsoc->no_email) ? 0 : 1)), 1, false, 1) . '</td>';
420
+	print '<td class="individualline noemail">'.$form->editfieldkey($langs->trans('No_Email').' ('.$langs->trans('Contact').')', 'contact_no_email', '', $objectsoc, 0).'</td>';
421
+	print '<td class="individualline" '.(($conf->browser->layout == 'phone') || !isModEnabled('mailing') ? ' colspan="3"' : '').'>'.$form->selectyesno('contact_no_email', (GETPOSTISSET("contact_no_email") ? GETPOST("contact_no_email", 'alpha') : (empty($objectsoc->no_email) ? 0 : 1)), 1, false, 1).'</td>';
422 422
 }
423 423
 print '</tr>';
424 424
 
425
-print '<tr><td>' . $form->editfieldkey('Web', 'url', '', $objectsoc, 0) . '</td>';
426
-print '<td>' . img_picto('', 'globe', 'class="pictofixedwidth"') . ' <input type="text" class="maxwidth500 widthcentpercentminusx" name="url" id="url" value="' . $objectsoc->url . '"></td></tr>';
425
+print '<tr><td>'.$form->editfieldkey('Web', 'url', '', $objectsoc, 0).'</td>';
426
+print '<td>'.img_picto('', 'globe', 'class="pictofixedwidth"').' <input type="text" class="maxwidth500 widthcentpercentminusx" name="url" id="url" value="'.$objectsoc->url.'"></td></tr>';
427 427
 
428 428
 
429 429
 // Comments
430 430
 print '<tr>';
431
-print '<td class="tdtop">' . $langs->trans("Comments") . '</td>';
432
-print '<td class="tdtop"><textarea name="note_private" id="note_private" wrap="soft" class="quatrevingtpercent" rows="' . ROWS_3 . '">' . dol_escape_htmltag(GETPOST('note_private', 'restricthtml'), 0, 1) . '</textarea></td>';
433
-print '</tr>' . "\n";
431
+print '<td class="tdtop">'.$langs->trans("Comments").'</td>';
432
+print '<td class="tdtop"><textarea name="note_private" id="note_private" wrap="soft" class="quatrevingtpercent" rows="'.ROWS_3.'">'.dol_escape_htmltag(GETPOST('note_private', 'restricthtml'), 0, 1).'</textarea></td>';
433
+print '</tr>'."\n";
434 434
 // TODO Move this into generic feature.
435 435
 
436 436
 
437 437
 
438 438
 // Display Captcha code if is enabled
439 439
 if (getDolGlobalString('MAIN_SECURITY_ENABLECAPTCHA')) {
440
-	require_once DOL_DOCUMENT_ROOT . '/core/lib/security2.lib.php';
441
-	print '<tr><td class="titlefield"><label for="email"><span class="fieldrequired">' . $langs->trans("SecurityCode") . '</span></label></td><td>';
440
+	require_once DOL_DOCUMENT_ROOT.'/core/lib/security2.lib.php';
441
+	print '<tr><td class="titlefield"><label for="email"><span class="fieldrequired">'.$langs->trans("SecurityCode").'</span></label></td><td>';
442 442
 	print '<span class="span-icon-security inline-block">';
443
-	print '<input id="securitycode" placeholder="' . $langs->trans("SecurityCode") . '" class="flat input-icon-security width150" type="text" maxlength="5" name="code" tabindex="3" />';
443
+	print '<input id="securitycode" placeholder="'.$langs->trans("SecurityCode").'" class="flat input-icon-security width150" type="text" maxlength="5" name="code" tabindex="3" />';
444 444
 	print '</span>';
445 445
 	print '<span class="nowrap inline-block">';
446
-	print '<img class="inline-block valignmiddle" src="' . DOL_URL_ROOT . '/core/antispamimage.php" border="0" width="80" height="32" id="img_securitycode" />';
447
-	print '<a class="inline-block valignmiddle" href="' . $php_self . '" tabindex="4" data-role="button">' . img_picto($langs->trans("Refresh"), 'refresh', 'id="captcha_refresh_img"') . '</a>';
446
+	print '<img class="inline-block valignmiddle" src="'.DOL_URL_ROOT.'/core/antispamimage.php" border="0" width="80" height="32" id="img_securitycode" />';
447
+	print '<a class="inline-block valignmiddle" href="'.$php_self.'" tabindex="4" data-role="button">'.img_picto($langs->trans("Refresh"), 'refresh', 'id="captcha_refresh_img"').'</a>';
448 448
 	print '</span>';
449 449
 	print '</td></tr>';
450 450
 }
@@ -455,9 +455,9 @@  discard block
 block discarded – undo
455 455
 
456 456
 // Save / Submit
457 457
 print '<div class="center">';
458
-print '<input type="submit" value="' . $langs->trans("Send") . '" id="submitsave" class="button">';
458
+print '<input type="submit" value="'.$langs->trans("Send").'" id="submitsave" class="button">';
459 459
 if (!empty($backtopage)) {
460
-	print ' &nbsp; &nbsp; <input type="submit" value="' . $langs->trans("Cancel") . '" id="submitcancel" class="button button-cancel">';
460
+	print ' &nbsp; &nbsp; <input type="submit" value="'.$langs->trans("Cancel").'" id="submitcancel" class="button button-cancel">';
461 461
 }
462 462
 print '</div>';
463 463
 
Please login to merge, or discard this patch.
htdocs/fichinter/list.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -74,7 +74,7 @@  discard block
 block discarded – undo
74 74
 $search_date_endday = GETPOSTINT('search_date_endday');
75 75
 $search_date_endmonth = GETPOSTINT('search_date_endmonth');
76 76
 $search_date_endyear = GETPOSTINT('search_date_endyear');
77
-$search_date_start = dol_mktime(0, 0, 0, $search_date_startmonth, $search_date_startday, $search_date_startyear);	// Use tzserver
77
+$search_date_start = dol_mktime(0, 0, 0, $search_date_startmonth, $search_date_startday, $search_date_startyear); // Use tzserver
78 78
 $search_date_end = dol_mktime(23, 59, 59, $search_date_endmonth, $search_date_endday, $search_date_endyear);
79 79
 $optioncss = GETPOST('optioncss', 'alpha');
80 80
 $socid = GETPOST('socid', 'int');
@@ -102,7 +102,7 @@  discard block
 block discarded – undo
102 102
 
103 103
 // Initialize technical object to manage hooks of page. Note that conf->hooks_modules contains array of hook context
104 104
 $object = new Fichinter($db);
105
-$hookmanager->initHooks(array($contextpage)); 	// Note that conf->hooks_modules contains array of activated contexes
105
+$hookmanager->initHooks(array($contextpage)); // Note that conf->hooks_modules contains array of activated contexes
106 106
 
107 107
 $extrafields = new ExtraFields($db);
108 108
 
@@ -408,7 +408,7 @@  discard block
 block discarded – undo
408 408
 // Output page
409 409
 // --------------------------------------------------------------------
410 410
 
411
-llxHeader('', $title, $help_url, '', 0, 0, $morejs, $morecss, '', 'bodyforlist');	// Can use also classforhorizontalscrolloftabs instead of bodyforlist for no horizontal scroll
411
+llxHeader('', $title, $help_url, '', 0, 0, $morejs, $morecss, '', 'bodyforlist'); // Can use also classforhorizontalscrolloftabs instead of bodyforlist for no horizontal scroll
412 412
 
413 413
 
414 414
 $arrayofselected = is_array($toselect) ? $toselect : array();
@@ -779,7 +779,7 @@  discard block
 block discarded – undo
779 779
 	$objectstatic->id = $obj->rowid;
780 780
 	$objectstatic->ref = $obj->ref;
781 781
 	$objectstatic->ref_client = $obj->ref_client;
782
-	$objectstatic->statut = $obj->status;	// deprecated
782
+	$objectstatic->statut = $obj->status; // deprecated
783 783
 	$objectstatic->status = $obj->status;
784 784
 
785 785
 	$companystatic->name = $obj->name;
Please login to merge, or discard this patch.