Debug v21
This commit is contained in:
parent
203a8e7c6a
commit
0774070182
5 changed files with 22 additions and 16 deletions
|
|
@ -265,7 +265,7 @@ class FormFile
|
|||
}
|
||||
|
||||
if (getDolGlobalString('MAIN_UPLOAD_DOC')) {
|
||||
if ($perm) {
|
||||
if ($perm && empty($conf->dol_optimize_smallscreen)) {
|
||||
$langs->load('other');
|
||||
|
||||
$menudolibarrsetupmax = $langs->transnoentitiesnoconv("Home").' - '.$langs->transnoentitiesnoconv("Setup").' - '.$langs->transnoentitiesnoconv("Security");
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ WEBSITE_ALIASALTDesc=Use here list of other name/aliases so the page can also be
|
|||
WEBSITE_CSS_URL=URL of external CSS file
|
||||
WEBSITE_CSS_INLINE=CSS file content (common to all pages)
|
||||
WEBSITE_JS_INLINE=JavaScript file content (common to all pages)
|
||||
WEBSITE_HTML_HEADER=Addition at bottom of HTML Header (common to all pages)
|
||||
WEBSITE_HTML_HEADER=HTML Header (common to all pages)
|
||||
WEBSITE_ROBOT=Robot file (robots.txt)
|
||||
WEBSITE_HTACCESS=Website .htaccess file
|
||||
WEBSITE_MANIFEST_JSON=Website manifest.json file
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ WEBSITE_ALIASALTDesc=Utilisez ici la liste des autres noms / alias afin que la p
|
|||
WEBSITE_CSS_URL=URL du fichier de la feuille de style (CSS) externe
|
||||
WEBSITE_CSS_INLINE=Contenu du fichier CSS (commun à toute les pages)
|
||||
WEBSITE_JS_INLINE=Contenu du fichier JavaScript (commun à toutes les pages)
|
||||
WEBSITE_HTML_HEADER=Ajout en bas de l'en-tête HTML (commun à toutes les pages)
|
||||
WEBSITE_HTML_HEADER=En-tête HTML (commun à toutes les pages)
|
||||
WEBSITE_ROBOT=Fichier robot (robots.txt)
|
||||
WEBSITE_HTACCESS=Fichier .htaccess du site web
|
||||
WEBSITE_MANIFEST_JSON=Fichier manifest.json de site Web
|
||||
|
|
|
|||
|
|
@ -1619,7 +1619,7 @@ if (is_object($objcanvas) && $objcanvas->displayCanvasExists($canvasdisplayactio
|
|||
if ($type == 1) {
|
||||
print '<tr><td>'.$langs->trans("Duration").'</td><td>';
|
||||
print img_picto('', 'clock', 'class="pictofixedwidth"');
|
||||
print '<input name="duration_value" size="4" value="'.GETPOSTINT('duration_value').'">';
|
||||
print '<input name="duration_value" class="width50" value="'.(GETPOSTISSET('duration_value') ? GETPOSTINT('duration_value') : '').'">';
|
||||
print $formproduct->selectMeasuringUnits("duration_unit", "time", (GETPOSTISSET('duration_unit') ? GETPOST('duration_unit', 'alpha') : 'h'), 0, 1);
|
||||
|
||||
// Mandatory period
|
||||
|
|
@ -2246,7 +2246,7 @@ if (is_object($objcanvas) && $objcanvas->displayCanvasExists($canvasdisplayactio
|
|||
if ($object->isService()) {
|
||||
// Duration
|
||||
print '<tr><td>'.$langs->trans("Duration").'</td><td>';
|
||||
print '<input name="duration_value" size="5" value="'.$object->duration_value.'"> ';
|
||||
print '<input name="duration_value" class="width50" value="'.($object->duration_value ? $object->duration_value : '').'"> ';
|
||||
print $formproduct->selectMeasuringUnits("duration_unit", "time", $object->duration_unit, 0, 1);
|
||||
|
||||
// Mandatory period
|
||||
|
|
|
|||
|
|
@ -1772,13 +1772,17 @@ if ($action == 'updatecss' && $usercanedit) {
|
|||
$errorphpcheck = checkPHPCode($phpfullcodestringold, $phpfullcodestring); // Contains the setEventMessages
|
||||
|
||||
if (!$errorphpcheck) {
|
||||
$htaccesscontent = '';
|
||||
$htaccesscontent .= $dataposted."\n";
|
||||
if ($dataposted) {
|
||||
$htaccesscontent = '';
|
||||
$htaccesscontent .= $dataposted."\n";
|
||||
|
||||
$result = dolSaveHtaccessFile($filehtaccess, $htaccesscontent);
|
||||
if (!$result) {
|
||||
$error++;
|
||||
setEventMessages('Failed to write file '.$filehtaccess, null, 'errors');
|
||||
$result = dolSaveHtaccessFile($filehtaccess, $htaccesscontent);
|
||||
if (!$result) {
|
||||
$error++;
|
||||
setEventMessages('Failed to write file '.$filehtaccess, null, 'errors');
|
||||
}
|
||||
} else {
|
||||
dol_delete_file($filehtaccess, 0, 0);
|
||||
}
|
||||
} else {
|
||||
$error++;
|
||||
|
|
@ -3868,10 +3872,6 @@ if ($action == 'editcss') {
|
|||
} else {
|
||||
$htaccesscontent = GETPOST('WEBSITE_HTACCESS', 'nohtml'); // We must use 'nohtml' and not 'alphanohtml' because we must accept "
|
||||
}
|
||||
if (!trim($htaccesscontent)) {
|
||||
$htaccesscontent .= "# Order allow,deny\n";
|
||||
$htaccesscontent .= "# Deny from all\n";
|
||||
}
|
||||
|
||||
if (!GETPOSTISSET('WEBSITE_MANIFEST_JSON')) {
|
||||
$manifestjsoncontent = @file_get_contents($filemanifestjson);
|
||||
|
|
@ -4034,7 +4034,13 @@ if ($action == 'editcss') {
|
|||
|
||||
// .htaccess
|
||||
print '<tr><td class="tdtop">';
|
||||
print $langs->trans('WEBSITE_HTACCESS');
|
||||
|
||||
$textwithhelp3 = $langs->trans("Example");
|
||||
$textwithhelp3 .= "<br># Order allow,deny\n";
|
||||
$textwithhelp3 .= "<br># Deny from all\n";
|
||||
$textwithhelp3 .= "<br># Require all granted\n";
|
||||
|
||||
print $form->textwithpicto($langs->trans('WEBSITE_HTACCESS'), $textwithhelp3, 1, 'help', '', 0, 2, 'htmlheadertooltip3');
|
||||
print '</td><td>';
|
||||
|
||||
$poscursor = array('x' => GETPOST('WEBSITE_HTACCESS_x'), 'y' => GETPOST('WEBSITE_HTACCESS_y'));
|
||||
|
|
|
|||
Loading…
Reference in a new issue