This commit is contained in:
Laurent Destailleur 2022-01-19 14:32:15 +01:00
parent fc7e8ed720
commit ed2ca6af79
5 changed files with 55 additions and 25 deletions

View File

@ -1888,7 +1888,7 @@ div.blockvmenulogo
margin-left: 11px;
margin-right: 9px;
padding: 0;
height: <?php echo $disableimages ? '20' : '35'; ?>px;
height: <?php echo $disableimages ? '18' : '35'; ?>px;
/* width: 100px; */
max-width: 100px;
vertical-align: middle;
@ -4936,6 +4936,11 @@ tr.visible {
/* Module website */
/* ============================================================================== */
.websiteformtoolbar {
position: sticky;
top: <?php echo $disableimages ? '32px' : '52px'; ?>;
}
.exampleapachesetup {
overflow-y: auto;
height: 100px;
@ -4988,7 +4993,13 @@ span[phptag] {
/* display: inline-block; */
padding-<?php echo $right; ?>: 10px;
vertical-align: middle;
/* line-height: 28px; */
line-height: 28px;
}
.websiteselectionsection {
font-size: 0.85em;
}
.websiteselection span {
vertical-align: middle;
}
.websitetools {
float: right;
@ -5000,7 +5011,7 @@ span[phptag] {
}
.websiteinputurl {
display: inline-block;
vertical-align: top;
vertical-align: middle;
line-height: 28px;
}
.websiteiframenoborder {
@ -5035,6 +5046,10 @@ span.websitebuttonsitepreviewdisabled img, a.websitebuttonsitepreviewdisabled im
line-height: 1em;
}
.websitebar input.bordertransp {
line-height: normal !important;
}
#divbodywebsite section p {
margin: unset;
}
@ -7340,7 +7355,7 @@ div.clipboardCPValue.hidewithsize {
.websiteselectionsection {
border-left: unset;
boerder-right: unset;
border-right: unset;
padding-left: 5px;
}

View File

@ -234,6 +234,7 @@ span.butActionNewRefused>span.fa, span.butActionNewRefused>span.fa:hover
background: var(--butactiondeletebg);
/* border: 1px solid #633; */
color: #633;
vertical-align: middle;
}
.butActionDelete:hover {

View File

@ -11,7 +11,7 @@
font-variant: normal;
text-rendering: auto;
line-height: 26px;
font-size: 1.5em;
font-size: 1.3em;
-webkit-font-smoothing: antialiased;
text-align:center;
text-decoration:none;

View File

@ -3041,11 +3041,11 @@ div.blockvmenulogo
border-bottom: 0 !important;
}
.menulogocontainer {
margin: <?php echo $disableimages ? '0' : '6'; ?>px;
margin: <?php echo $disableimages ? '-1' : '6'; ?>px;
margin-left: 12px;
margin-right: 6px;
padding: 0;
height: <?php echo $disableimages ? '20' : '32'; ?>px;
height: <?php echo $disableimages ? '18' : '32'; ?>px;
/* width: 100px; */
max-width: 100px;
vertical-align: middle;
@ -4862,6 +4862,11 @@ tr.visible {
/* Module website */
/* ============================================================================== */
.websiteformtoolbar {
position: sticky;
top: <?php echo $disableimages ? '36px' : '50px'; ?>;
}
.exampleapachesetup {
overflow-y: auto;
max-height: 100px;
@ -4891,7 +4896,10 @@ span[phptag] {
border-bottom: 1px solid #ccc;
background: #eee;
display: inline-block;
padding: 4px 0 4px 0;
padding: 5px 5px 5px 5px;
}
.centpercent.websitebar {
width: calc(100% - 10px);
}
.websitebar .buttonDelete, .websitebar .button {
text-shadow: none;
@ -4908,7 +4916,7 @@ span[phptag] {
}
.websiteselection {
/* display: inline-block; */
padding-left: 10px;
padding-<?php echo $right; ?>: 10px;
vertical-align: middle;
}
.websitetools {
@ -7126,7 +7134,7 @@ div.clipboardCPValue.hidewithsize {
.websiteselectionsection {
border-left: unset;
boerder-right: unset;
border-right: unset;
padding-left: 5px;
}

View File

@ -2508,7 +2508,7 @@ llxHeader($moreheadcss.$moreheadjs, $langs->trans("WebsiteSetup"), $helpurl, '',
print "\n";
print '<!-- Open form for all page -->'."\n";
print '<form action="'.$_SERVER["PHP_SELF"].($action == 'file_manager' ? '?uploadform=1': '').'" method="POST" enctype="multipart/form-data">';
print '<form action="'.$_SERVER["PHP_SELF"].($action == 'file_manager' ? '?uploadform=1': '').'" method="POST" enctype="multipart/form-data" class="websiteformtoolbar">';
print '<input type="hidden" name="token" value="'.newToken().'">';
print '<input type="hidden" name="backtopage" value="'.$backtopage.'">';
@ -2669,7 +2669,7 @@ if (!GETPOST('hide_websitemenu')) {
print ' &nbsp; ';
//print '<input type="submit" class="button bordertransp"'.$disabled.' value="'.dol_escape_htmltag($langs->trans("EditCss")).'" name="editcss">';
print '<a href="'.$_SERVER["PHP_SELF"].'?website='.$object->ref.'&pageid='.$pageid.'&action=editcss&token='.newToken().'" class="button bordertransp"'.$disabled.'>'.dol_escape_htmltag($langs->trans($conf->dol_optimize_smallscreen ? "Properties" : "EditCss")).'</a>';
print '<a href="'.$_SERVER["PHP_SELF"].'?website='.$object->ref.'&pageid='.$pageid.'&action=editcss&token='.newToken().'" class="button bordertransp" title="'.dol_escape_htmltag($langs->trans("EditCss")).'"'.$disabled.'><span class="fa fa-cog paddingrightonly"></span><span class="hideonsmartphone">'.dol_escape_htmltag($langs->trans("EditCss")).'</span></a>';
$importlabel = $langs->trans("ImportSite");
$exportlabel = $langs->trans("ExportSite");
@ -2692,24 +2692,24 @@ if (!GETPOST('hide_websitemenu')) {
print '<input type="submit" class="buttonDelete bordertransp" name="deletesite" value="'.$langs->trans("Delete").'"'.($atleastonepage ? ' disabled="disabled"' : '').'>';
// Regenerate all pages
print '<a href="'.$_SERVER["PHP_SELF"].'?action=regeneratesite&website='.$website->ref.'" class="button bordertransp"'.$disabled.' title="'.dol_escape_htmltag($langs->trans("RegenerateWebsiteContent")).'"><span class="fa fa-cogs"><span></a>';
print '<a href="'.$_SERVER["PHP_SELF"].'?action=regeneratesite&website='.$website->ref.'" class="button bordertransp"'.$disabled.' title="'.dol_escape_htmltag($langs->trans("RegenerateWebsiteContent")).'"><span class="far fa-hdd"></span></a>';
// Generate site map
print '<a href="'.$_SERVER["PHP_SELF"].'?action=confirmgeneratesitemaps&website='.$website->ref.'" class="button bordertransp"'.$disabled.' title="'.dol_escape_htmltag($langs->trans("GenerateSitemaps")).'"><span class="fa fa-sitemap"><span></a>';
print '<a href="'.$_SERVER["PHP_SELF"].'?action=confirmgeneratesitemaps&website='.$website->ref.'" class="button bordertransp"'.$disabled.' title="'.dol_escape_htmltag($langs->trans("GenerateSitemaps")).'"><span class="fa fa-sitemap"></span></a>';
print '<a href="'.$_SERVER["PHP_SELF"].'?action=replacesite&website='.$website->ref.'" class="button bordertransp"'.$disabled.' title="'.dol_escape_htmltag($langs->trans("ReplaceWebsiteContent")).'"><span class="fa fa-search"><span></a>';
print '<a href="'.$_SERVER["PHP_SELF"].'?action=replacesite&website='.$website->ref.'" class="button bordertransp"'.$disabled.' title="'.dol_escape_htmltag($langs->trans("ReplaceWebsiteContent")).'"><span class="fa fa-search"></span></a>';
}
print '</span>';
if ($websitekey && $websitekey != '-1' && ($action == 'preview' || $action == 'createfromclone' || $action == 'createpagefromclone' || $action == 'deletesite')) {
print '<span class="websiteselection">';
//print '<a href="'.$_SERVER["PHP_SELF"].'?action=file_manager&website='.$website->ref.'" class="button bordertransp"'.$disabled.' title="'.dol_escape_htmltag($langs->trans("MediaFiles")).'"><span class="fa fa-image"><span></a>';
print dolButtonToOpenUrlInDialogPopup('file_manager', $langs->transnoentitiesnoconv("MediaFiles"), '<span class="fa fa-image"><span>', '/website/index.php?action=file_manager&website='.$website->ref, $disabled);
//print '<a href="'.$_SERVER["PHP_SELF"].'?action=file_manager&website='.$website->ref.'" class="button bordertransp"'.$disabled.' title="'.dol_escape_htmltag($langs->trans("MediaFiles")).'"><span class="fa fa-image"></span></a>';
print dolButtonToOpenUrlInDialogPopup('file_manager', $langs->transnoentitiesnoconv("MediaFiles"), '<span class="fa fa-image"></span>', '/website/index.php?action=file_manager&website='.$website->ref, $disabled);
if (!empty($conf->categorie->enabled)) {
//print '<a href="'.DOL_URL_ROOT.'/categories/index.php?leftmenu=website&dol_hide_leftmenu=1&nosearch=1&type=website_page&website='.$website->ref.'" class="button bordertransp"'.$disabled.' title="'.dol_escape_htmltag($langs->trans("Categories")).'"><span class="fa fa-tags"><span></a>';
print dolButtonToOpenUrlInDialogPopup('categories', $langs->transnoentitiesnoconv("Categories"), '<span class="fa fa-tags"><span>', '/categories/index.php?leftmenu=website&nosearch=1&type=website_page&website='.$website->ref, $disabled);
//print '<a href="'.DOL_URL_ROOT.'/categories/index.php?leftmenu=website&dol_hide_leftmenu=1&nosearch=1&type=website_page&website='.$website->ref.'" class="button bordertransp"'.$disabled.' title="'.dol_escape_htmltag($langs->trans("Categories")).'"><span class="fa fa-tags"></span></a>';
print dolButtonToOpenUrlInDialogPopup('categories', $langs->transnoentitiesnoconv("Categories"), '<span class="fa fa-tags"></span>', '/categories/index.php?leftmenu=website&nosearch=1&type=website_page&website='.$website->ref, $disabled);
}
print '</span>';
@ -2808,7 +2808,7 @@ if (!GETPOST('hide_websitemenu')) {
print '</span>';
print '<span class="websiteselection hideonsmartphoneimp">';
print '<a href="'.$_SERVER["PHP_SELF"].'?action=createcontainer&website='.$website->ref.'" class="button bordertransp"'.$disabled.' title="'.dol_escape_htmltag($langs->trans("AddPage")).'"><span class="fa fa-plus-circle valignmiddle btnTitle-icon"><span></a>';
print '<a href="'.$_SERVER["PHP_SELF"].'?action=createcontainer&website='.$website->ref.'" class="button bordertransp"'.$disabled.' title="'.dol_escape_htmltag($langs->trans("AddPage")).'"><span class="fa fa-plus-circle valignmiddle btnTitle-icon"></span></a>';
print '</span>';
//print '<span class="websiteselection">';
@ -2846,9 +2846,10 @@ if (!GETPOST('hide_websitemenu')) {
print $langs->trans("New");
}
//print '<input type="submit" class="button" name="refreshpage" value="'.$langs->trans("Load").'"'.($atleastonepage?'':' disabled="disabled"').'>';
print '<input type="image" class="valignmiddle" src="'.img_picto('', 'refresh', '', 0, 1).'" name="refreshpage" value="'.$langs->trans("Load").'"'.(($atleastonepage && $action != 'editsource') ? '' : ' disabled="disabled"').'>';
print '<span class="websiteselection">';
print '<input type="image" class="valignmiddle" src="'.img_picto('', 'refresh', '', 0, 1).'" name="refreshpage" value="'.$langs->trans("Load").'"'.(($atleastonepage && $action != 'editsource') ? '' : ' disabled="disabled"').'>';
// Print nav arrows
$pagepreviousid = 0;
@ -2887,6 +2888,8 @@ if (!GETPOST('hide_websitemenu')) {
print '<span class="valignmiddle opacitymedium">'.img_next($langs->trans("Next")).'</span>';
}
print '</span>';
$websitepage = new WebSitePage($db);
if ($pageid > 0 && ($action == 'preview' || $action == 'createfromclone' || $action == 'createpagefromclone')) {
$websitepage->fetch($pageid);
@ -2962,13 +2965,16 @@ if (!GETPOST('hide_websitemenu')) {
print $formconfirm;
}
print '<span class="websiteselection">';
print ' &nbsp; ';
//print '<input type="submit" class="button bordertransp"'.$disabled.' value="'.dol_escape_htmltag($langs->trans("EditPageMeta")).'" name="editmeta">';
print '<a href="'.$_SERVER["PHP_SELF"].'?website='.$object->ref.'&pageid='.$pageid.'&action=editmeta&token='.newToken().'" class="button bordertransp"'.$disabled.'>'.dol_escape_htmltag($langs->trans($conf->dol_optimize_smallscreen ? "Properties" : "EditPageMeta")).'</a>';
print '<a href="'.$_SERVER["PHP_SELF"].'?website='.$object->ref.'&pageid='.$pageid.'&action=editmeta&token='.newToken().'" class="button bordertransp" title="'.dol_escape_htmltag($langs->trans("EditPageMeta")).'"'.$disabled.'><span class="fa fa-cog paddingrightonly"></span><span class="hideonsmartphone">'.dol_escape_htmltag($langs->trans("EditPageMeta")).'</span></a>';
//print '<input type="submit" class="button bordertransp"'.$disabled.' value="'.dol_escape_htmltag($langs->trans("EditHTMLSource")).'" name="editsource">';
print '<a href="'.$_SERVER["PHP_SELF"].'?website='.$object->ref.'&pageid='.$pageid.'&action=editsource&token='.newToken().'" class="button bordertransp"'.$disabled.'>'.dol_escape_htmltag($langs->trans($conf->dol_optimize_smallscreen ? "HTML" : "EditHTMLSource")).'</a>';
print '</span>';
print '<!-- button EditInLine and ShowSubcontainers -->'."\n";
print '<div class="websiteselectionsection inline-block">';
@ -3055,11 +3061,11 @@ if (!GETPOST('hide_websitemenu')) {
//$disabled=' disabled="disabled"';
//print '<span class="button bordertransp disabled"'.$disabled.' title="'.dol_escape_htmltag($langs->trans("SetAsHomePage")).'"><span class="fa fa-home"></span></span>';
//print '<input type="submit" class="button bordertransp" disabled="disabled" value="'.dol_escape_htmltag($langs->trans("SetAsHomePage")).'" name="setashome">';
print '<a href="#" class="button bordertransp disabled" disabled="disabled" title="'.dol_escape_htmltag($langs->trans("SetAsHomePage")).'"><span class="fa fa-home valignmiddle btnTitle-icon"><span></a>';
print '<a href="#" class="button bordertransp disabled" disabled="disabled" title="'.dol_escape_htmltag($langs->trans("SetAsHomePage")).'"><span class="fa fa-home valignmiddle btnTitle-icon"></span></a>';
} else {
//$disabled='';
//print '<input type="submit" class="button bordertransp"'.$disabled.' value="'.dol_escape_htmltag($langs->trans("SetAsHomePage")).'" name="setashome">';
print '<a href="'.$_SERVER["PHP_SELF"].'?action=setashome&token='.newToken().'&website='.$website->ref.'&pageid='.$pageid.'" class="button bordertransp"'.$disabled.' title="'.dol_escape_htmltag($langs->trans("SetAsHomePage")).'"><span class="fa fa-home valignmiddle btnTitle-icon"><span></a>';
print '<a href="'.$_SERVER["PHP_SELF"].'?action=setashome&token='.newToken().'&website='.$website->ref.'&pageid='.$pageid.'" class="button bordertransp"'.$disabled.' title="'.dol_escape_htmltag($langs->trans("SetAsHomePage")).'"><span class="fa fa-home valignmiddle btnTitle-icon"></span></a>';
}
print '<input type="submit" class="button bordertransp"'.$disabled.' value="'.dol_escape_htmltag($langs->trans("ClonePage")).'" name="createpagefromclone">';
print '<input type="submit" class="buttonDelete bordertransp" name="delete" value="'.$langs->trans("Delete").'"'.($atleastonepage ? '' : ' disabled="disabled"').'>';