From 979bcd3a9b225c7e7e6b672a4fb8b6ea390f2240 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Fri, 31 Mar 2017 11:39:12 +0200 Subject: [PATCH] NEW Can add a background image on login page --- htdocs/admin/company.php | 40 ++-- htdocs/admin/ihm.php | 181 ++++++++++++++++-- htdocs/cashdesk/index.php | 2 +- htdocs/cashdesk/tpl/ticket.tpl.php | 2 +- htdocs/core/lib/files.lib.php | 2 +- htdocs/core/lib/security2.lib.php | 4 +- htdocs/core/menus/standard/auguria.lib.php | 2 +- htdocs/core/menus/standard/eldy.lib.php | 4 +- htdocs/core/tpl/login.tpl.php | 28 ++- htdocs/core/tpl/passwordforgotten.tpl.php | 26 +-- .../mycompany/background_computer_coffee.jpg | Bin 0 -> 385205 bytes htdocs/langs/en_US/admin.lang | 2 + htdocs/margin/tabs/productMargins.php | 2 +- htdocs/opensurvey/fonctions.php | 2 +- htdocs/product/document.php | 3 +- htdocs/product/fournisseurs.php | 5 +- htdocs/product/info.php | 3 +- htdocs/product/note.php | 2 +- htdocs/product/price.php | 3 +- htdocs/product/stock/product.php | 3 +- htdocs/public/members/new.php | 4 +- htdocs/public/paybox/newpayment.php | 4 +- htdocs/public/paypal/newpayment.php | 4 +- htdocs/theme/eldy/style.css.php | 17 +- htdocs/theme/md/style.css.php | 16 +- htdocs/user/passwordforgotten.php | 4 +- htdocs/viewimage.php | 4 +- 27 files changed, 270 insertions(+), 99 deletions(-) create mode 100644 htdocs/install/doctemplates/mycompany/background_computer_coffee.jpg diff --git a/htdocs/admin/company.php b/htdocs/admin/company.php index 0f8efb23da0..d73f23d0ef7 100644 --- a/htdocs/admin/company.php +++ b/htdocs/admin/company.php @@ -31,6 +31,7 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/company.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/images.lib.php'; +require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formother.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formcompany.class.php'; @@ -51,8 +52,6 @@ $error=0; if ( ($action == 'update' && empty($_POST["cancel"])) || ($action == 'updateedit') ) { - require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; - $tmparray=getCountry(GETPOST('country_id','int'),'all',$db,$langs,0); if (! empty($tmparray['id'])) { @@ -76,21 +75,23 @@ if ( ($action == 'update' && empty($_POST["cancel"])) dolibarr_set_const($db, "MAIN_INFO_SOCIETE_WEB",$_POST["web"],'chaine',0,'',$conf->entity); dolibarr_set_const($db, "MAIN_INFO_SOCIETE_NOTE",$_POST["note"],'chaine',0,'',$conf->entity); dolibarr_set_const($db, "MAIN_INFO_SOCIETE_GENCOD",$_POST["barcode"],'chaine',0,'',$conf->entity); - if ($_FILES["logo"]["tmp_name"]) + + $varforimage='logo'; $dirforimage=$conf->mycompany->dir_output.'/logos/'; + if ($_FILES[$varforimage]["tmp_name"]) { - if (preg_match('/([^\\/:]+)$/i',$_FILES["logo"]["name"],$reg)) + if (preg_match('/([^\\/:]+)$/i',$_FILES[$varforimage]["name"],$reg)) { $original_file=$reg[1]; $isimage=image_format_supported($original_file); if ($isimage >= 0) { - dol_syslog("Move file ".$_FILES["logo"]["tmp_name"]." to ".$conf->mycompany->dir_output.'/logos/'.$original_file); - if (! is_dir($conf->mycompany->dir_output.'/logos/')) + dol_syslog("Move file ".$_FILES[$varforimage]["tmp_name"]." to ".$dirforimage.$original_file); + if (! is_dir($dirforimage)) { - dol_mkdir($conf->mycompany->dir_output.'/logos/'); + dol_mkdir($dirforimage); } - $result=dol_move_uploaded_file($_FILES["logo"]["tmp_name"],$conf->mycompany->dir_output.'/logos/'.$original_file,1,0,$_FILES['logo']['error']); + $result=dol_move_uploaded_file($_FILES[$varforimage]["tmp_name"],$dirforimage.$original_file,1,0,$_FILES[$varforimage]['error']); if ($result > 0) { dolibarr_set_const($db, "MAIN_INFO_SOCIETE_LOGO",$original_file,'chaine',0,'',$conf->entity); @@ -101,8 +102,8 @@ if ( ($action == 'update' && empty($_POST["cancel"])) // Create thumbs //$object->addThumbs($newfile); // We can't use addThumbs here yet because we need name of generated thumbs to add them into constants. TODO Check if need such constants. We should be able to retreive value with get... - // Used on logon for example - $imgThumbSmall = vignette($conf->mycompany->dir_output.'/logos/'.$original_file, $maxwidthsmall, $maxheightsmall, '_small', $quality); + // Create small thumb, Used on logon for example + $imgThumbSmall = vignette($dirforimage.$original_file, $maxwidthsmall, $maxheightsmall, '_small', $quality); if (image_format_supported($imgThumbSmall) >= 0 && preg_match('/([^\\/:]+)$/i',$imgThumbSmall,$reg)) { $imgThumbSmall = $reg[1]; // Save only basename @@ -110,9 +111,8 @@ if ( ($action == 'update' && empty($_POST["cancel"])) } else dol_syslog($imgThumbSmall); - // Create mini thumbs for company (Ratio is near 16/9) - // Used on menu or for setup page for example - $imgThumbMini = vignette($conf->mycompany->dir_output.'/logos/'.$original_file, $maxwidthmini, $maxheightmini, '_mini', $quality); + // Create mini thumb, Used on menu or for setup page for example + $imgThumbMini = vignette($dirforimage.$original_file, $maxwidthmini, $maxheightmini, '_mini', $quality); if (image_format_supported($imgThumbMini) >= 0 && preg_match('/([^\\/:]+)$/i',$imgThumbMini,$reg)) { $imgThumbMini = $reg[1]; // Save only basename @@ -143,6 +143,7 @@ if ( ($action == 'update' && empty($_POST["cancel"])) } } } + dolibarr_set_const($db, "MAIN_INFO_SOCIETE_MANAGERS",$_POST["MAIN_INFO_SOCIETE_MANAGERS"],'chaine',0,'',$conf->entity); dolibarr_set_const($db, "MAIN_INFO_CAPITAL",$_POST["capital"],'chaine',0,'',$conf->entity); dolibarr_set_const($db, "MAIN_INFO_SOCIETE_FORME_JURIDIQUE",$_POST["forme_juridique_code"],'chaine',0,'',$conf->entity); @@ -196,7 +197,7 @@ if ( ($action == 'update' && empty($_POST["cancel"])) } } -if ($action == 'addthumb') +if ($action == 'addthumb') // Regenerate thumbs { if (file_exists($conf->mycompany->dir_output.'/logos/'.$_GET["file"])) { @@ -208,7 +209,7 @@ if ($action == 'addthumb') // Create thumbs //$object->addThumbs($newfile); // We can't use addThumbs here yet because we need name of generated thumbs to add them into constants. TODO Check if need such constants. We should be able to retreive value with get... - // Used on logon for example + // Create small thumb. Used on logon for example $imgThumbSmall = vignette($conf->mycompany->dir_output.'/logos/'.$_GET["file"], $maxwidthsmall, $maxheightsmall, '_small',$quality); if (image_format_supported($imgThumbSmall) >= 0 && preg_match('/([^\\/:]+)$/i',$imgThumbSmall,$reg)) { @@ -217,8 +218,7 @@ if ($action == 'addthumb') } else dol_syslog($imgThumbSmall); - // Create mini thumbs for company (Ratio is near 16/9) - // Used on menu or for setup page for example + // Create mini thumbs. Used on menu or for setup page for example $imgThumbMini = vignette($conf->mycompany->dir_output.'/logos/'.$_GET["file"], $maxwidthmini, $maxheightmini, '_mini',$quality); if (image_format_supported($imgThumbSmall) >= 0 && preg_match('/([^\\/:]+)$/i',$imgThumbMini,$reg)) { @@ -300,7 +300,7 @@ if ($action == 'edit' || $action == 'updateedit') });'; print ''."\n"; - print '
'; + print ''; print ''; print ''; $var=true; @@ -383,7 +383,7 @@ if ($action == 'edit' || $action == 'updateedit') print ''.img_delete($langs->trans("Delete")).''; if (file_exists($conf->mycompany->dir_output.'/logos/thumbs/'.$mysoc->logo_mini)) { print '   '; - print ''; + print ''; } } else { print ''; @@ -775,7 +775,7 @@ else } else if ($mysoc->logo_mini && is_file($conf->mycompany->dir_output.'/logos/thumbs/'.$mysoc->logo_mini)) { - print ''; + print ''; } else { diff --git a/htdocs/admin/ihm.php b/htdocs/admin/ihm.php index 83f6701e2a1..ff3bb89946b 100644 --- a/htdocs/admin/ihm.php +++ b/htdocs/admin/ihm.php @@ -26,6 +26,8 @@ require '../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/usergroups.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php'; +require_once DOL_DOCUMENT_ROOT.'/core/lib/images.lib.php'; +require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formother.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formadmin.class.php'; @@ -70,6 +72,26 @@ if (GETPOST('cancel')) $action=''; } +if ($action == 'removebackgroundlogin' && ! empty($conf->global->MAIN_LOGIN_BACKGROUND)) +{ + require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; + + $logofile=$conf->mycompany->dir_output.'/logos/'.$conf->global->MAIN_LOGIN_BACKGROUND; + dol_delete_file($logofile); + dolibarr_del_const($db, "MAIN_LOGIN_BACKGROUND",$conf->entity); + $mysoc->logo=''; + + /*$logosmallfile=$conf->mycompany->dir_output.'/logos/thumbs/'.$mysoc->logo_small; + dol_delete_file($logosmallfile); + dolibarr_del_const($db, "MAIN_INFO_SOCIETE_LOGO_SMALL",$conf->entity); + $mysoc->logo_small=''; + + $logominifile=$conf->mycompany->dir_output.'/logos/thumbs/'.$mysoc->logo_mini; + dol_delete_file($logominifile); + dolibarr_del_const($db, "MAIN_INFO_SOCIETE_LOGO_MINI",$conf->entity); + $mysoc->logo_mini='';*/ +} + if ($action == 'update') { dolibarr_set_const($db, "MAIN_LANG_DEFAULT", $_POST["main_lang_default"],'chaine',0,'',$conf->entity); @@ -123,6 +145,78 @@ if ($action == 'update') // This one is not always defined if (isset($_POST["MAIN_USE_PREVIEW_TABS"])) dolibarr_set_const($db, "MAIN_USE_PREVIEW_TABS", $_POST["MAIN_USE_PREVIEW_TABS"],'chaine',0,'',$conf->entity); + $varforimage='imagebackground'; $dirforimage=$conf->mycompany->dir_output.'/logos/'; + if ($_FILES[$varforimage]["tmp_name"]) + { + if (preg_match('/([^\\/:]+)$/i',$_FILES[$varforimage]["name"],$reg)) + { + $original_file=$reg[1]; + + $isimage=image_format_supported($original_file); + if ($isimage >= 0) + { + dol_syslog("Move file ".$_FILES[$varforimage]["tmp_name"]." to ".$dirforimage.$original_file); + if (! is_dir($dirforimage)) + { + dol_mkdir($dirforimage); + } + $result=dol_move_uploaded_file($_FILES[$varforimage]["tmp_name"],$dirforimage.$original_file,1,0,$_FILES[$varforimage]['error']); + if ($result > 0) + { + dolibarr_set_const($db, "MAIN_LOGIN_BACKGROUND",$original_file,'chaine',0,'',$conf->entity); + + // Create thumbs of logo (Note that PDF use original file and not thumbs) + /* + if ($isimage > 0) + { + // Create thumbs + //$object->addThumbs($newfile); // We can't use addThumbs here yet because we need name of generated thumbs to add them into constants. TODO Check if need such constants. We should be able to retreive value with get... + + // Create small thumb, Used on logon for example + $imgThumbSmall = vignette($dirforimage.$original_file, $maxwidthsmall, $maxheightsmall, '_small', $quality); + if (image_format_supported($imgThumbSmall) >= 0 && preg_match('/([^\\/:]+)$/i',$imgThumbSmall,$reg)) + { + $imgThumbSmall = $reg[1]; // Save only basename + dolibarr_set_const($db, "MAIN_INFO_SOCIETE_LOGO_SMALL",$imgThumbSmall,'chaine',0,'',$conf->entity); + } + else dol_syslog($imgThumbSmall); + + // Create mini thumb, Used on menu or for setup page for example + $imgThumbMini = vignette($dirforimage.$original_file, $maxwidthmini, $maxheightmini, '_mini', $quality); + if (image_format_supported($imgThumbMini) >= 0 && preg_match('/([^\\/:]+)$/i',$imgThumbMini,$reg)) + { + $imgThumbMini = $reg[1]; // Save only basename + dolibarr_set_const($db, "MAIN_INFO_SOCIETE_LOGO_MINI",$imgThumbMini,'chaine',0,'',$conf->entity); + } + else dol_syslog($imgThumbMini); + } + else dol_syslog("ErrorImageFormatNotSupported",LOG_WARNING); + */ + } + else if (preg_match('/^ErrorFileIsInfectedWithAVirus/',$result)) + { + $error++; + $langs->load("errors"); + $tmparray=explode(':',$result); + setEventMessages($langs->trans('ErrorFileIsInfectedWithAVirus',$tmparray[1]), null, 'errors'); + } + else + { + $error++; + setEventMessages($langs->trans("ErrorFailedToSaveFile"), null, 'errors'); + } + } + else + { + $error++; + $langs->load("errors"); + setEventMessages($langs->trans("ErrorBadImageFormat"), null, 'errors'); + } + } + } + + + $_SESSION["mainmenu"]=""; // Le gestionnaire de menu a pu changer header("Location: ".$_SERVER["PHP_SELF"]."?mainmenu=home&leftmenu=setup"); @@ -152,7 +246,7 @@ if ($action == 'edit') // Edit //WYSIWYG Editor require_once DOL_DOCUMENT_ROOT.'/core/class/doleditor.class.php'; - print ''; + print ''; print ''; print ''; @@ -160,7 +254,7 @@ if ($action == 'edit') // Edit print '
'; print ''; - print ''; + print ''; print ''; print ''; @@ -315,14 +409,6 @@ if ($action == 'edit') // Edit print ''; print ''; - // Message on login page - print ''."\n"; - // Message of the day on home page print '
'.$langs->trans("Parameters").''.$langs->trans("Value").'
'.$langs->trans("Language").' 
 
'.$langs->trans("MessageLogin").''; - - $doleditor = new DolEditor('main_home', (isset($conf->global->MAIN_HOME)?$conf->global->MAIN_HOME:''), '', 142, 'dolibarr_notes', 'In', false, true, true, ROWS_4, '90%'); - $doleditor->Create(); - - print '
'.$langs->trans("MessageOfDay").''; @@ -333,6 +419,40 @@ if ($action == 'edit') // Edit print '
'."\n"; + print '
'; + + // Other + print ''; + print ''; + print ''; + print ''; + + // Message on login page + print ''."\n"; + + // Logo + $var=!$var; + print ''; + + print '
'.$langs->trans("LoginPage").' 
'.$langs->trans("MessageLogin").''; + $doleditor = new DolEditor('main_home', (isset($conf->global->MAIN_HOME)?$conf->global->MAIN_HOME:''), '', 142, 'dolibarr_notes', 'In', false, true, true, ROWS_4, '90%'); + $doleditor->Create(); + print '
'; + print '
'; + print ''; + print ''; + if (! empty($conf->global->MAIN_LOGIN_BACKGROUND)) { + print ''.img_delete($langs->trans("Delete")).''; + if (file_exists($conf->mycompany->dir_output.'/logos/'.$conf->global->MAIN_LOGIN_BACKGROUND)) { + print '   '; + print ''; + } + } else { + print ''; + } + print '
'; + print '
'."\n"; + print '
'; print ''; @@ -346,7 +466,7 @@ else // Show { // Language print ''; - print ''; + print ''; print ''; - // Message login - print ''."\n"; - // Message of the day print '
'.$langs->trans("Parameters").''.$langs->trans("Value").' 
'.$langs->trans("Language").' 
'.$langs->trans("DefaultLanguage").''; $s=picto_from_langcode($conf->global->MAIN_LANG_DEFAULT); @@ -486,12 +606,6 @@ else // Show print yn((isset($conf->global->MAIN_HELPCENTER_DISABLELINK)?$conf->global->MAIN_HELPCENTER_DISABLELINK:0),1); print '
'.$langs->trans("MessageLogin").''; - if (isset($conf->global->MAIN_HOME)) print dol_htmlcleanlastbr($conf->global->MAIN_HOME); - else print ' '; - print '
'.$langs->trans("MessageOfDay").''; if (isset($conf->global->MAIN_MOTD)) print dol_htmlcleanlastbr($conf->global->MAIN_MOTD); @@ -500,6 +614,39 @@ else // Show print '
'."\n"; + print '
'; + + // Login page + print ''; + print ''; + + // Message login + print ''."\n"; + + // Background login + // Logo + $var=!$var; + print ''; + + print '
'.$langs->trans("LoginPage").' 
'.$langs->trans("MessageLogin").''; + if (isset($conf->global->MAIN_HOME)) print dol_htmlcleanlastbr($conf->global->MAIN_HOME); + else print ' '; + print '
'.$langs->trans("BackgroundImageLogin").''; + print '
'; + print $conf->global->MAIN_LOGIN_BACKGROUND; + print '
'; + // It offers the generation of the thumbnail if it does not exist + if ($conf->global->MAIN_LOGIN_BACKGROUND && is_file($conf->mycompany->dir_output.'/logos/'.$conf->global->MAIN_LOGIN_BACKGROUND)) + { + print ''; + } + else + { + print ''; + } + print '
'; + print '
'."\n"; + print '
'; print ''.$langs->trans("Modify").''; print '
'; diff --git a/htdocs/cashdesk/index.php b/htdocs/cashdesk/index.php index 9a61a50b38a..8f6af8b6d4d 100644 --- a/htdocs/cashdesk/index.php +++ b/htdocs/cashdesk/index.php @@ -63,7 +63,7 @@ top_htmlhead('','',0,0,'',$arrayofcss); logo_small)) { - print 'Logo company'; + print 'Logo company'; } else { diff --git a/htdocs/cashdesk/tpl/ticket.tpl.php b/htdocs/cashdesk/tpl/ticket.tpl.php index 78ce86f45f7..40be470c429 100644 --- a/htdocs/cashdesk/tpl/ticket.tpl.php +++ b/htdocs/cashdesk/tpl/ticket.tpl.php @@ -37,7 +37,7 @@ $object->fetch($facid);

name; ?>
diff --git a/htdocs/core/lib/files.lib.php b/htdocs/core/lib/files.lib.php index 1cb4da03488..0d4c1dff71e 100644 --- a/htdocs/core/lib/files.lib.php +++ b/htdocs/core/lib/files.lib.php @@ -1590,7 +1590,7 @@ function dol_check_secure_access_document($modulepart,$original_file,$entity,$fu $relative_original_file = $original_file; // Wrapping for some images - if ($modulepart == 'companylogo' && !empty($conf->mycompany->dir_output)) + if (($modulepart == 'mycompany' || $modulepart == 'companylogo') && !empty($conf->mycompany->dir_output)) { $accessallowed=1; $original_file=$conf->mycompany->dir_output.'/logos/'.$original_file; diff --git a/htdocs/core/lib/security2.lib.php b/htdocs/core/lib/security2.lib.php index fc05e2c9194..cadf133169d 100644 --- a/htdocs/core/lib/security2.lib.php +++ b/htdocs/core/lib/security2.lib.php @@ -227,11 +227,11 @@ function dol_loginfunction($langs,$conf,$mysoc) if (! empty($mysoc->logo_small) && is_readable($conf->mycompany->dir_output.'/logos/thumbs/'.$mysoc->logo_small)) { - $urllogo=DOL_URL_ROOT.'/viewimage.php?cache=1&modulepart=companylogo&file='.urlencode('thumbs/'.$mysoc->logo_small); + $urllogo=DOL_URL_ROOT.'/viewimage.php?cache=1&modulepart=mycompany&file='.urlencode('thumbs/'.$mysoc->logo_small); } elseif (! empty($mysoc->logo) && is_readable($conf->mycompany->dir_output.'/logos/'.$mysoc->logo)) { - $urllogo=DOL_URL_ROOT.'/viewimage.php?cache=1&modulepart=companylogo&file='.urlencode($mysoc->logo); + $urllogo=DOL_URL_ROOT.'/viewimage.php?cache=1&modulepart=mycompany&file='.urlencode($mysoc->logo); $width=128; } elseif (is_readable(DOL_DOCUMENT_ROOT.'/theme/'.$conf->theme.'/img/dolibarr_logo.png')) diff --git a/htdocs/core/menus/standard/auguria.lib.php b/htdocs/core/menus/standard/auguria.lib.php index 2c2d2c5ec63..e95359e5683 100644 --- a/htdocs/core/menus/standard/auguria.lib.php +++ b/htdocs/core/menus/standard/auguria.lib.php @@ -257,7 +257,7 @@ function print_left_auguria_menu($db,$menu_array_before,$menu_array_after,&$tabM $mysoc->logo_mini=$conf->global->MAIN_INFO_SOCIETE_LOGO_MINI; if (! empty($mysoc->logo_mini) && is_readable($conf->mycompany->dir_output.'/logos/thumbs/'.$mysoc->logo_mini)) { - $urllogo=DOL_URL_ROOT.'/viewimage.php?cache=1&modulepart=companylogo&file='.urlencode('thumbs/'.$mysoc->logo_mini); + $urllogo=DOL_URL_ROOT.'/viewimage.php?cache=1&modulepart=mycompany&file='.urlencode('thumbs/'.$mysoc->logo_mini); } else { diff --git a/htdocs/core/menus/standard/eldy.lib.php b/htdocs/core/menus/standard/eldy.lib.php index 178f1ca9db7..ccf6902a289 100644 --- a/htdocs/core/menus/standard/eldy.lib.php +++ b/htdocs/core/menus/standard/eldy.lib.php @@ -466,7 +466,7 @@ function print_left_eldy_menu($db,$menu_array_before,$menu_array_after,&$tabMenu $mysoc->logo_mini=$conf->global->MAIN_INFO_SOCIETE_LOGO_MINI; if (! empty($mysoc->logo_mini) && is_readable($conf->mycompany->dir_output.'/logos/thumbs/'.$mysoc->logo_mini)) { - $urllogo=DOL_URL_ROOT.'/viewimage.php?cache=1&modulepart=companylogo&file='.urlencode('thumbs/'.$mysoc->logo_mini); + $urllogo=DOL_URL_ROOT.'/viewimage.php?cache=1&modulepart=mycompany&file='.urlencode('thumbs/'.$mysoc->logo_mini); } else { @@ -478,7 +478,7 @@ function print_left_eldy_menu($db,$menu_array_before,$menu_array_after,&$tabMenu print '

'; print ''; print ''; print ''; print '
'."\n"; diff --git a/htdocs/core/tpl/login.tpl.php b/htdocs/core/tpl/login.tpl.php index e0aa28ce2d6..a23d14a979d 100644 --- a/htdocs/core/tpl/login.tpl.php +++ b/htdocs/core/tpl/login.tpl.php @@ -45,7 +45,7 @@ print top_htmlhead('', $titleofloginpage, 0, 0, $arrayofjs, array(), 0, $disable ?> - +global->MAIN_LOGIN_BACKGROUND)?'':' style="background-image: url(\''.DOL_URL_ROOT.'/viewimage.php?cache=1&noalt=1&modulepart=mycompany&file='.urlencode($conf->global->MAIN_LOGIN_BACKGROUND).'\')"'; ?>> dol_use_jmobile)) { ?> -
+