26if (!defined(
'NOLOGIN')) {
29if (!defined(
'NOCSRFCHECK')) {
30 define(
"NOCSRFCHECK", 1);
32if (!defined(
'NOIPCHECK')) {
33 define(
'NOIPCHECK',
'1');
35if (!defined(
'NOBROWSERNOTIF')) {
36 define(
'NOBROWSERNOTIF',
'1');
43$entity = (!empty($_GET[
'entity']) ? (int) $_GET[
'entity'] : (!empty($_POST[
'entity']) ? (int) $_POST[
'entity'] : 1));
44if (is_numeric($entity)) {
45 define(
"DOLENTITY", $entity);
49require
'../../main.inc.php';
50require_once DOL_DOCUMENT_ROOT.
'/core/lib/company.lib.php';
51require_once DOL_DOCUMENT_ROOT.
'/core/class/extrafields.class.php';
52require_once DOL_DOCUMENT_ROOT.
'/eventorganization/class/conferenceorbooth.class.php';
53require_once DOL_DOCUMENT_ROOT.
'/projet/class/project.class.php';
54require_once DOL_DOCUMENT_ROOT.
'/contact/class/contact.class.php';
55require_once DOL_DOCUMENT_ROOT.
'/categories/class/categorie.class.php';
56require_once DOL_DOCUMENT_ROOT.
'/compta/facture/class/facture.class.php';
57require_once DOL_DOCUMENT_ROOT.
'/compta/facture/class/paymentterm.class.php';
58require_once DOL_DOCUMENT_ROOT.
'/core/class/html.formcompany.class.php';
59require_once DOL_DOCUMENT_ROOT.
'/core/lib/date.lib.php';
77$backtopage =
GETPOST(
'backtopage',
'alpha');
78$action =
GETPOST(
'action',
'aZ09');
90$resultproject = $project->fetch((
int) $id);
91if ($resultproject < 0) {
93 $errmsg .= $project->error;
97$securekeyreceived =
GETPOST(
'securekey',
'alpha');
100if ($securekeytocompare != $securekeyreceived) {
101 print $langs->trans(
'MissingOrBadSecureKey');
106$langs->loadLangs(array(
"main",
"companies",
"install",
"other",
"eventorganization"));
109$hookmanager->initHooks(array(
'publicnewmembercard',
'globalcard'));
113$user->loadDefaultValues();
116$arrayofconfboothtype = $cactioncomm->liste_array(
'',
'id',
'', 0,
"module='booth@eventorganization'");
117if ($arrayofconfboothtype == -1) {
118 $arrayofconfboothtype = [];
139function llxHeaderVierge($title, $head =
"", $disablejs = 0, $disablehead = 0, $arrayofjs = [], $arrayofcss = [])
141 global $conf, $langs,
$mysoc;
143 top_htmlhead($head, $title, $disablejs, $disablehead, $arrayofjs, $arrayofcss);
145 print
'<body id="mainbody" class="publicnewmemberform">';
148 $urllogo = DOL_URL_ROOT.
'/theme/common/login_logo.png';
150 if (!empty(
$mysoc->logo_small) && is_readable($conf->mycompany->dir_output.
'/logos/thumbs/'.
$mysoc->logo_small)) {
151 $urllogo = DOL_URL_ROOT.
'/viewimage.php?cache=1&modulepart=mycompany&file='.urlencode(
'logos/thumbs/'.
$mysoc->logo_small);
152 } elseif (!empty(
$mysoc->logo) && is_readable($conf->mycompany->dir_output.
'/logos/'.
$mysoc->logo)) {
153 $urllogo = DOL_URL_ROOT.
'/viewimage.php?cache=1&modulepart=mycompany&file='.urlencode(
'logos/'.
$mysoc->logo);
154 } elseif (is_readable(DOL_DOCUMENT_ROOT.
'/theme/dolibarr_logo.svg')) {
155 $urllogo = DOL_URL_ROOT.
'/theme/dolibarr_logo.svg';
158 print
'<div class="center">';
162 print
'<div class="backgreypublicpayment">';
163 print
'<div class="logopublicpayment">';
164 print
'<img id="dolpaymentlogo" src="'.$urllogo.
'"';
168 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>';
174 print
'<div class="backimagepublicsuggestbooth">';
175 print
'<img id="idPROJECT_IMAGE_PUBLIC_SUGGEST_BOOTH" src="' .
getDolGlobalString(
'PROJECT_IMAGE_PUBLIC_SUGGEST_BOOTH').
'">';
181 print
'<div class="divmainbodylarge">';
207$parameters = array();
209$reshook = $hookmanager->executeHooks(
'doActions', $parameters, $project, $action);
215if (empty($reshook) && $action ==
'add') {
224 $errmsg .= $langs->trans(
"ErrorFieldRequired", $langs->transnoentitiesnoconv(
"Name")).
"<br>\n";
228 $errmsg .= $langs->trans(
"ErrorFieldRequired", $langs->transnoentitiesnoconv(
"Email")).
"<br>\n";
230 if (!
GETPOST(
"country_id") && !empty((
float) $project->price_booth)) {
232 $errmsg .= $langs->trans(
"ErrorFieldRequired", $langs->transnoentitiesnoconv(
"Country")).
"<br>\n";
236 $errmsg .= $langs->trans(
"ErrorFieldRequired", $langs->transnoentitiesnoconv(
"ThirdParty")).
"<br>\n";
240 $errmsg .= $langs->trans(
"ErrorFieldRequired", $langs->transnoentitiesnoconv(
"Label")).
"<br>\n";
244 $errmsg .= $langs->trans(
"ErrorFieldRequired", $langs->transnoentitiesnoconv(
"Note")).
"<br>\n";
248 $langs->load(
"errors");
249 $errmsg .= $langs->trans(
"ErrorBadEMail",
GETPOST(
"email")).
"<br>\n";
256 $thirdparty =
new Societe($db);
257 $resultfetchthirdparty = $thirdparty->fetch(0, $societe);
259 if ($resultfetchthirdparty < 0) {
262 $errmsg .= $thirdparty->error;
263 $errors = array_merge($errors, $thirdparty->errors);
264 } elseif ($resultfetchthirdparty == 0) {
266 $genericcompanyname =
'Unknown company';
268 if (!empty($societe)) {
269 $thirdparty->name = $societe;
271 $thirdparty->name = $genericcompanyname;
273 $thirdparty->address =
GETPOST(
"address");
274 $thirdparty->zip =
GETPOST(
"zipcode");
275 $thirdparty->town =
GETPOST(
"town");
276 $thirdparty->client = $thirdparty::PROSPECT;
277 $thirdparty->fournisseur = 0;
278 $thirdparty->country_id =
GETPOSTINT(
"country_id");
279 $thirdparty->state_id =
GETPOSTINT(
"state_id");
280 $thirdparty->email = ($emailcompany ? $emailcompany : $email);
284 if (substr($module, 0, 15) ==
'mod_codeclient_' && substr($module, -3) ==
'php') {
285 $module = substr($module, 0,
dol_strlen($module) - 4);
287 $dirsociete = array_merge(array(
'/core/modules/societe/'), $conf->modules_parts[
'societe']);
288 foreach ($dirsociete as $dirroot) {
294 $modCodeClient =
new $module($db);
295 '@phan-var-force ModeleThirdPartyCode $modCodeClient';
298 if (empty($tmpcode) && !empty($modCodeClient->code_auto)) {
299 $tmpcode = $modCodeClient->getNextValue($thirdparty, 0);
301 $thirdparty->code_client = $tmpcode;
302 $readythirdparty = $thirdparty->create($user);
303 if ($readythirdparty < 0) {
305 $errmsg .= $thirdparty->error;
306 $errors = array_merge($errors, $thirdparty->errors);
308 $thirdparty->country_code =
getCountry($thirdparty->country_id,
'2', $db, $langs);
309 $thirdparty->country =
getCountry($thirdparty->country_code,
'', $db, $langs);
315 $resultcontact = $contact->fetch(0,
null,
'', $email);
316 if ($resultcontact <= 0) {
318 $contact->socid = $thirdparty->id;
319 $contact->lastname = (string)
GETPOST(
"lastname",
'alpha');
320 $contact->firstname = (string)
GETPOST(
"firstname",
'alpha');
321 $contact->address = (string)
GETPOST(
"address",
'alpha');
322 $contact->zip = (string)
GETPOST(
"zipcode",
'alpha');
323 $contact->town = (string)
GETPOST(
"town",
'alpha');
324 $contact->country_id =
GETPOSTINT(
"country_id");
326 $contact->email = $email;
327 $contact->status = 1;
328 $contact->statut = 1;
330 $resultcreatecontact = $contact->create($user);
331 if ($resultcreatecontact < 0) {
333 $errmsg .= $contact->error;
342 $resultcategory = $category->fetch(
getDolGlobalInt(
'EVENTORGANIZATION_CATEG_THIRDPARTY_BOOTH'));
344 if ($resultcategory <= 0) {
346 $errmsg .= $category->error;
348 $resultsetcategory = $thirdparty->setCategoriesCommon(array($category->id), Categorie::TYPE_CUSTOMER,
false);
349 if ($resultsetcategory < 0) {
351 $errmsg .= $thirdparty->error;
353 $thirdparty->fournisseur = 1;
357 if (substr($module, 0, 15) ==
'mod_codeclient_' && substr($module, -3) ==
'php') {
358 $module = substr($module, 0,
dol_strlen($module) - 4);
360 $dirsociete = array_merge(array(
'/core/modules/societe/'), $conf->modules_parts[
'societe']);
361 foreach ($dirsociete as $dirroot) {
367 $modCodeFournisseur =
new $module($db);
368 '@phan-var-force ModeleThirdPartyCode $modCodeFournisseur';
370 if (empty($tmpcode) && !empty($modCodeFournisseur->code_auto)) {
371 $tmpcode = $modCodeFournisseur->getNextValue($thirdparty, 1);
373 $thirdparty->code_fournisseur = $tmpcode;
375 $res = $thirdparty->update(0, $user, 1, 1, 1);
387 $conforbooth->label = $label;
388 $conforbooth->fk_soc = $thirdparty->id;
389 $conforbooth->fk_project = $project->id;
390 $conforbooth->note = $note;
391 $conforbooth->fk_action = $eventtype;
392 $conforbooth->datep = $datestart;
393 $conforbooth->datep2 = $dateend;
394 $conforbooth->datec =
dol_now();
398 $nb_post_max =
getDolGlobalInt(
"MAIN_SECURITY_MAX_POST_ON_PUBLIC_PAGES_BY_IP_ADDRESS", 200);
404 if ($nb_post_max > 0) {
405 $sql =
"SELECT COUNT(ref) as nb_confs";
406 $sql .=
" FROM ".MAIN_DB_PREFIX.
"actioncomm";
407 $sql .=
" WHERE ip = '".$db->escape($conforbooth->ip).
"'";
408 $sql .=
" AND datec > '".$db->idate($minmonthpost).
"'";
409 $resql = $db->query($sql);
411 $num = $db->num_rows($resql);
415 $obj = $db->fetch_object($resql);
416 $nb_post_ip = $obj->nb_confs;
421 $resultconforbooth = 0;
423 if ($nb_post_max > 0 && $nb_post_ip >= $nb_post_max) {
425 $errmsg .= $langs->trans(
"AlreadyTooMuchPostOnThisIPAdress");
426 array_push($conforbooth->errors, $langs->trans(
"AlreadyTooMuchPostOnThisIPAdress"));
429 $resultconforbooth = $conforbooth->create($user);
431 if ($resultconforbooth <= 0) {
433 $errmsg .= $conforbooth->error;
436 $resultaddcontact = $conforbooth->add_contact($contact->id,
'RESPONSIBLE');
437 if ($resultaddcontact < 0) {
439 $errmsg .= $conforbooth->error;
443 if (!empty((
float) $project->price_booth)) {
444 $productforinvoicerow =
new Product($db);
445 $resultprod = $productforinvoicerow->fetch(
getDolGlobalInt(
'SERVICE_BOOTH_LOCATION'));
446 if ($resultprod < 0) {
448 $errmsg .= $productforinvoicerow->error;
452 $facture->socid = $thirdparty->id;
455 $facture->cond_reglement_id = $contact->cond_reglement_id;
456 $facture->fk_project = $project->id;
458 if (empty($facture->cond_reglement_id)) {
459 $paymenttermstatic =
new PaymentTerm($contact->db);
460 $facture->cond_reglement_id = $paymenttermstatic->getDefaultId();
461 if (empty($facture->cond_reglement_id)) {
463 $contact->error =
'ErrorNoPaymentTermRECEPFound';
464 $contact->errors[] = $contact->error;
467 $resultfacture = $facture->create($user);
468 if ($resultfacture <= 0) {
469 $contact->setErrorsFromObject($facture);
473 $facture->add_object_linked($conforbooth->element, $conforbooth->id);
477 if (!$error && is_object($facture)) {
480 $result = $facture->addline($langs->trans(
"BoothLocationFee", $conforbooth->label,
dol_print_date($conforbooth->datep,
'%d/%m/%y %H:%M:%S'),
dol_print_date($conforbooth->datep2,
'%d/%m/%y %H:%M:%S')), (
float) $project->price_booth, 1, $vattouse, 0, 0, $productforinvoicerow->id, 0,
dol_now(),
'', 0, 0, 0,
'HT', 0, 1);
482 $contact->setErrorsFromObject($facture);
503 $conforbooth->status = ConferenceOrBooth::STATUS_SUGGESTED;
504 $conforbooth->update($user);
511 if (!$error && is_object($thirdparty)) {
515 require_once DOL_DOCUMENT_ROOT.
'/core/class/CMailFile.class.php';
516 include_once DOL_DOCUMENT_ROOT.
'/core/class/html.formmail.class.php';
520 $outputlangs->setDefaultLang(empty($thirdparty->default_lang) ?
$mysoc->default_lang : $thirdparty->default_lang);
522 $outputlangs->loadLangs(array(
"main",
"members",
"eventorganization"));
524 $arraydefaultmessage =
null;
526 $labeltouse =
getDolGlobalInt(
'EVENTORGANIZATION_TEMPLATE_EMAIL_ASK_BOOTH');
527 if (!empty($labeltouse)) {
528 $arraydefaultmessage = $formmail->getEMailTemplate($db,
'conferenceorbooth', $user, $outputlangs, $labeltouse, 1,
'');
533 if (!empty($labeltouse) && is_object($arraydefaultmessage) && $arraydefaultmessage->id > 0) {
534 $subject = $arraydefaultmessage->topic;
535 $msg = $arraydefaultmessage->content;
538 $substitutionarray = getCommonSubstitutionArray($outputlangs, 0,
null, $thirdparty);
544 $sendto = $thirdparty->email;
546 $urlback = $_SERVER[
"REQUEST_URI"];
547 $trackid =
'proj'.$project->id;
551 $mailfile =
new CMailFile($subjecttosend, $sendto, $from, $texttosend, array(), array(), array(),
'',
'', 0, $ishtml ? 1 : 0,
'',
'', $trackid);
553 $result = $mailfile->sendfile();
555 dol_syslog(
"EMail sent to ".$sendto, LOG_DEBUG, 0,
'_payment');
557 dol_syslog(
"Failed to send EMail to ".$sendto, LOG_ERR, 0,
'_payment');
562 header(
"Location: ".$redirection);
574$form =
new Form($db);
580print
'<div align="center">';
581print
'<div id="divsubscribe">';
586print
'<div class="center subscriptionformbanner subbanner justify margintoponly paddingtop marginbottomonly padingbottom">';
587print
load_fiche_titre($langs->trans(
"NewSuggestionOfBooth"),
'',
'', 0,
'',
'center');
589print
'<span class="opacitymedium">'.$langs->trans(
"EvntOrgRegistrationWelcomeMessage").
'</span>';
592print
'<span class="eventlabel large">'.dol_escape_htmltag($project->title .
' '. $project->label).
'</span><br>';
597print
'<div class="justify subscriptionformhelptext">';
599if ($project->date_start_event || $project->date_end_event) {
600 print
'<br><span class="fa fa-calendar pictofixedwidth opacitymedium"></span>';
602if ($project->date_start_event) {
604 $tmparray =
dol_getdate($project->date_start_event,
false,
'');
605 if ($tmparray[
'hours'] || $tmparray[
'minutes'] || $tmparray[
'minutes']) {
610if ($project->date_start_event && $project->date_end_event) {
613if ($project->date_end_event) {
615 $tmparray =
dol_getdate($project->date_end_event,
false,
'');
616 if ($tmparray[
'hours'] || $tmparray[
'minutes'] || $tmparray[
'minutes']) {
621if ($project->date_start_event || $project->date_end_event) {
624if ($project->location) {
625 print
'<span class="fa fa-map-marked-alt pictofixedwidth opacitymedium"></span>'.dol_escape_htmltag($project->location).
'<br>';
627if ($project->note_public) {
628 print
'<br><!-- note public --><span class="opacitymedium">'.dol_htmlentitiesbr($project->note_public).
'</span><br>';
639print
'<form action="'.$_SERVER[
"PHP_SELF"].
'" method="POST" name="newmember">'.
"\n";
640print
'<input type="hidden" name="token" value="'.newToken().
'" / >';
641print
'<input type="hidden" name="entity" value="'.$entity.
'" />';
642print
'<input type="hidden" name="action" value="add" />';
643print
'<input type="hidden" name="id" value="'.$id.
'" />';
644print
'<input type="hidden" name="securekey" value="'.$securekeyreceived.
'" />';
647print
'<br><span class="opacitymedium">'.$langs->trans(
"FieldsWithAreMandatory",
'*').
'</span><br>';
652print
'<script type="text/javascript">
653jQuery(document).ready(function () {
654 jQuery(document).ready(function () {
655 jQuery("#selectcountry_id").change(function() {
656 document.newmember.action.value="create";
657 document.newmember.submit();
663print
'<table class="border" summary="form to subscribe" id="tablesubscribe">'.
"\n";
666print
'<tr><td><label for="lastname">'.$langs->trans(
"Lastname").
'<span class="star">*</span></label></td>';
667print
'<td colspan="3"><input name="lastname" id="lastname" type="text" class="maxwidth100onsmartphone" maxlength="80" value="'.dol_escape_htmltag(
GETPOST(
"lastname",
'alpha') ?
GETPOST(
"lastname",
'alpha') :
$object->lastname).
'" autofocus="autofocus"></td>';
670print
'<tr><td>'.$langs->trans(
"Email").
'<span class="star">*</span></td><td><input type="text" name="email" maxlength="255" class="minwidth150" value="'.
dol_escape_htmltag(
GETPOST(
'email')).
'"></td></tr>'.
"\n";
672print
'<tr id="trcompany" class="trcompany"><td>'.$langs->trans(
"Company").
'<span class="star">*</span>';
673print
' </td><td><input type="text" name="societe" class="minwidth150" value="'.dol_escape_htmltag(
GETPOST(
'societe')).
'"></td></tr>'.
"\n";
675print
'<tr><td>'.$langs->trans(
"Address").
'</td><td>'.
"\n";
676print
'<textarea name="address" id="address" wrap="soft" class="quatrevingtpercent" rows="'.ROWS_3.
'">'.
dol_escape_htmltag(
GETPOST(
'address',
'restricthtml'), 0, 1).
'</textarea></td></tr>'.
"\n";
678print
'<tr><td>'.$langs->trans(
'Zip').
' / '.$langs->trans(
'Town').
'</td><td>';
679print $formcompany->select_ziptown(
GETPOST(
'zipcode'),
'zipcode', array(
'town',
'selectcountry_id',
'state_id'), 6, 1);
681print $formcompany->select_ziptown(
GETPOST(
'town'),
'town', array(
'zipcode',
'selectcountry_id',
'state_id'), 0, 1);
684print
'<tr><td>'.$langs->trans(
'Country');
685print
'<span class="star">*</span>';
687$country_id =
GETPOST(
'country_id');
689 $country_id =
getCountry($conf->global->MEMBER_NEWFORM_FORCECOUNTRYCODE,
'2', $db, $langs);
691if (!$country_id && !empty($conf->geoipmaxmind->enabled)) {
695 $new_country_id =
getCountry($country_code,
'3', $db, $langs);
697 if ($new_country_id) {
698 $country_id = $new_country_id;
702$country_code =
getCountry($country_id,
'2', $db, $langs);
703print $form->select_country($country_id,
'country_id');
707 print
'<tr><td>'.$langs->trans(
'State').
'</td><td>';
709 print $formcompany->select_state(
GETPOSTINT(
"state_id"), $country_code);
716print
'<tr><td>'.$langs->trans(
"Format").
'<span class="star">*</span></td>'.
"\n";
717print
'<td>'.Form::selectarray(
'eventtype', $arrayofconfboothtype, $eventtype, 1).
'</td>';
719print
'<tr><td>'.$langs->trans(
"LabelOfBooth").
'<span class="star">*</span></td>'.
"\n";
720print
'</td><td><input type="text" name="label" class="minwidth150" value="'.dol_escape_htmltag(
GETPOST(
'label')).
'"></td></tr>'.
"\n";
722print
'<tr><td>'.$langs->trans(
"Description").
'<span class="star">*</span></td>'.
"\n";
723print
'<td><textarea name="note" id="note" wrap="soft" class="quatrevingtpercent" rows="'.ROWS_3.
'">'.
dol_escape_htmltag(
GETPOST(
'note',
'restricthtml'), 0, 1).
'</textarea></td></tr>'.
"\n";
731print
'<div class="center">';
733print
'<input type="submit" value="'.$langs->trans(
"SuggestBooth").
'" name="suggestbooth" id="suggestbooth" class="button">';
$id
Support class for third parties, contacts, members, users or resources.
if(! $sortfield) if(! $sortorder) $object
global $dolibarr_main_url_root
llxFooterVierge()
Footer function.
Class to manage different types of events.
Class to send emails (with attachments or not) Usage: $mailfile = new CMailFile($subject,...
Class to manage categories.
Class for ConferenceOrBooth.
Class to manage invoices.
const TYPE_STANDARD
Standard invoice.
Class to manage payment terms records in dictionary.
Class to manage products or services.
Class to manage projects.
Class to manage third parties objects (customers, suppliers, prospects...)
Class to manage translations.
getCountry($searchkey, $withcode='', $dbtouse=null, $outputlangs=null, $entconv=1, $searchlabel='')
Return country label, code or id from an id, code or label.
dol_time_plus_duree($time, $duration_value, $duration_unit, $ruleforendofmonth=0)
Add a delay to a date.
dol_now($mode='gmt')
Return date for now.
dol_mktime($hour, $minute, $second, $month, $day, $year, $gm='auto', $check=1)
Return a timestamp date built from detailed information (by default a local PHP server timestamp) Rep...
setEventMessages($mesg, $mesgs, $style='mesgs', $messagekey='', $noduplicate=0, $attop=0)
Set event messages in dol_events session object.
GETPOSTINT($paramname, $method=0)
Return the value of a $_GET or $_POST supervariable, converted into integer.
dol_get_fiche_head($links=array(), $active='', $title='', $notab=0, $picto='', $pictoisfullpath=0, $morehtmlright='', $morecss='', $limittoshow=0, $moretabssuffix='', $dragdropfile=0, $morecssdiv='')
Show tabs of a record.
dol_user_country()
Return country code for current user.
dol_get_fiche_end($notab=0)
Return tab footer of a card.
setEventMessage($mesgs, $style='mesgs', $noduplicate=0, $attop=0)
Set event message in dol_events session object.
printCommonFooter($zone='private')
Print common footer : conf->global->MAIN_HTML_FOOTER js for switch of menu hider js for conf->global-...
dol_strlen($string, $stringencoding='UTF-8')
Make a strlen call.
getDolGlobalInt($key, $default=0)
Return a Dolibarr global constant int value.
if(!function_exists( 'dol_getprefix')) dol_include_once($relpath, $classname='')
Make an include_once using default root and alternate root if it fails.
complete_substitutions_array(&$substitutionarray, $outputlangs, $object=null, $parameters=null, $callfunc="completesubstitutionarray")
Complete the $substitutionarray with more entries coming from external module that had set the "subst...
make_substitutions($text, $substitutionarray, $outputlangs=null, $converttextinhtmlifnecessary=0)
Make substitution into a text string, replacing keys with vals from $substitutionarray (oldval=>newva...
dol_textishtml($msg, $option=0)
Return if a text is a html content.
GETPOST($paramname, $check='alphanohtml', $method=0, $filter=null, $options=null, $noreplace=0)
Return value of a param into GET or POST supervariable.
dol_print_date($time, $format='', $tzoutput='auto', $outputlangs=null, $encodetooutput=false, $decorate=0)
Output date in a string format according to outputlangs (or langs if not defined).
getUserRemoteIP($trusted=0)
Return the real IP of remote user.
load_fiche_titre($title, $morehtmlright='', $picto='generic', $pictoisfullpath=0, $id='', $morecssontable='', $morehtmlcenter='', $morecssonpicto='widthpictotitle')
Load a title with picto.
isValidEmail($address, $acceptsupervisorkey=0, $acceptuserkey=0)
Return true if email syntax is ok.
getDolGlobalString($key, $default='')
Return a Dolibarr global constant string value.
isModEnabled($module)
Is Dolibarr module enabled.
get_default_tva(Societe $thirdparty_seller, Societe $thirdparty_buyer, $idprod=0, $idprodfournprice=0)
Function that return vat rate of a product line (according to seller, buyer and product vat rate) VAT...
dol_htmloutput_errors($mesgstring='', $mesgarray=array(), $keepembedded=0)
Print formatted error messages to output (Used to show messages on html output).
dol_syslog($message, $level=LOG_INFO, $ident=0, $suffixinfilename='', $restricttologhandler='', $logcontext=null)
Write log message into outputs.
dol_getdate($timestamp, $fast=false, $forcetimezone='')
Return an array with locale date info.
dol_escape_htmltag($stringtoescape, $keepb=0, $keepn=0, $noescapetags='', $escapeonlyhtmltags=0, $cleanalsojavascript=0)
Returns text escaped for inclusion in HTML alt or title or value tags, or into values of HTML input f...
top_htmlhead($head, $title='', $disablejs=0, $disablehead=0, $arrayofjs=array(), $arrayofcss=array(), $disableforlogin=0, $disablenofollow=0, $disablenoindex=0)
Output html header of a page.
httponly_accessforbidden($message='1', $http_response_code=403, $stringalreadysanitized=0)
Show a message to say access is forbidden and stop program.
dol_hash($chain, $type='0', $nosalt=0, $mode=0)
Returns a hash (non reversible encryption) of a string.
if($arrayofconfboothtype==-1) if(!isModEnabled( 'eventorganization')) llxHeaderVierge($title, $head="", $disablejs=0, $disablehead=0, $arrayofjs=[], $arrayofcss=[])
Show header for new member.